f. OpenVMS FAQ -&- page 14)b @5z

HP OpenVMS Systems Documentation

 q> $"b,
Content starts here"D

The OpenVMS Frequently Asked Questions (FAQ)


 l n  
PreviousContentsIndex



;OpenVMS can read ODS-2, ODS-5, and ISO-9660 format CD-ROMs.C(If you are very careful, you can create a dual-format CD-R; a CD-RAwith both ODS-2 and ISO-9660 or both ODS-5 and ISO-9660 or both.)

InfoServerA hardware configurations are no longer available from HP, but may@ potentially be acquired through other means; as used equipment.@ InfoServer support also has very specific CD-R recording deviceC prerequisites, and these recording devices are no longer generally available.

DPackages related to the use of DVD archiving are also available, seeAthe multi-volume capabilities of the DVDarchive/restore Freeware.

 

"
ZF http://www.geocities.com/SiliconValley/Lakes/9999/vmscdwri.html  




;Additional information is available at the following sites:



U.S. DesignE offers a package that includes the tools necessary to create a CD or; DVD-R with either ISO-9660 or ODS-2 format, for standalone@CD-R/RW, DVD-R, or DVD+R/RW drives, for recent OpenVMS versions.Details are available at:



{Also see Section 9.7.2 for details on access to recorded media on olderCD-ROM drives.H

9.7.1 CD and DVD notation, terminology?



BCD-ROM is pre-recorded Compact Disk media, and is the original andAoldest CD format. The original CD media was physically stamped, aDrecording process that is now largely reserved to the highest-volume media reproduction requirements.

FCD-R is CD Recordable, a write-once storage medium that can be read byEall but the oldest of CD drives; a format which can be read and often#even recorded by most CD-RW drives.

DCD-RW is CD ReWritable, a format which is readable by many CD drives@and by most CD-R drives, and with media that can be recorded andre-recorded by CD-RW drives.

FCD media recording speeds are listed as multiples of 150 kilobytes perDsecond, so a 10X drive records at 1500 kilobytes (1.5 megabytes) per=second. 600 MB (70 minutes) and 700 MB (80 minutes) recording@capacities are both widely available. The minutes designation isCderived from the traditional audio-format recording capacity of theparticular media.

:DVD-R/RW is the older of two common Digital Versatile DiskFrecording formats, and the DVD-R Recordable or DVD-RW ReWritable media@can be read by many DVD drives. As with CD-R formats in older CDCdrives, older DVD and particularly first-generation DVD players may(have problems reading this media format.

>DVD+R/RW is the newer of the two common Digital Versatile DiskFrecording formats, and the DVD+R Recordable or DVD+RW ReWritable mediaAcan be read by many DVD drives. Akin to DVD-R/RW media, older andGparticularly first-generation DVD drives can have problems reading this media format.

EThe DVD Plus-series drives and media tend to record faster than MinusEdrives, as (as of this writing) the Plus (+) drives do not require anDinitial media formatting pass and the Minus (-) drives do. While theFappropriate Plus (+) or Minus (-) DVD raw media must be chosen for theEparticular DVD recorder (and DVD recording drives that are compatibleGwith and capable of using both Plus and Minus media are available), theGresulting recorded media is generally readable (playable) in all recentFDVD drives and DVD players, regardless of type. (Compatibility is bestAwithin the same media-series devices of course, but be certain toGverify compatibility across devices regardless of the particular device&or particular recording media chosen.)

GPresently Plus (+) media is slightly more expensive than Minus (-), butFwith the prices of all CD and all DVD media continuing to consistentlyDfall, the differences in DVD media costs are becoming irrelevent for4all but the production of huge volumes of DVD media.

EThe rated DVD recording speeds are in multiples of 1353 kilobytes perEsecond, thus a DVD 1X drive is roughly equivalent to a CD 9X drive in$I/O requirements and transfer speed.

EDVD drive recording speed can and does vary. DVD disk drive recordingGspeed is limited by the rated recording speed of the media used, so theDslower (and cheaper) DVD media will not record any more quickly in aFfaster drive. A 2.4X DVD drive loaded with 1X media will record at 1X.[

9.7.2 Use of RRD42 and other older (embossed-media) CD drives?



The RRD42G series SCSI CD-ROM drive is sufficiently old that it can have problemsC processing CD-R and CD-RW media. Other very old CD drives can haveG equivalent media compatibility problems when attempting to read (much)F newer CD media and newer CD media technologies. These older CD drives2 are generally intended for use with the so-calledD embossed media, rather than with non-embossed recorded (recordable)! media now in common circulation.

EPlease consider using a slightly-less-ancient CD-ROM or CD-R or CD-RW7drive when working with non-embossed recorded CD media.

GTo paraphrase one knowledgable---though deliberately nameless---storage?engineer, "The RRD42 drive is just past the drooling idiot stage".d

9.7.3 Creating Bootable OpenVMS I64 CD or DVD Media? SYS$SETBOOT?



CIf you are creating a bootable CD or DVD media for use with OpenVMSEI64, you will want to specify the SYS$SETBOOT block size of 2048, andGyou will also want a disk cluster factor that is a multiple of four viaCINITIALIZE/CLUSTER=4 (or 8, or...), or you will want to ensure that#SYS$EFI.SYS and SYS$DIAGNOSTICS.SYSGare aligned to a multiple of four blocks; to a 2048 byte boundary. ThisGalignment and this blocking is only necessary for OpenVMS I64, and only7when creating optical media OpenVMS I64 for bootstraps.

EThe default 512-byte block setting used by SYS$SETBOOT is the correctAand expected value for traditional disk bootstraps on OpenVMS I64systems.

BOnce the boot files are loaded, OpenVMS I64 operates with 512-byte=blocks; as is the case with ATAPI disks on OpenVMS Alpha, allBapplication code will only see 512-byte blocks on optical media on OpenVMS I64.

<OpenVMS I64 V8.2 and later are expected to have a version ofFSYS$SETBOOT that will flag a misaligned SYS$EFI.SYS and (if present) a$misaligned SYS$DIAGNOSTICS.SYS file.

DFor information on SYS$SETBOOT and the SET BOOTBLOCK command, pleasesee Section 14.3.9 and see the OpenVMS documentation. The purpose andDintent of the SYS$SETBOOT.EXE image and the SET BOOTBLOCK command is@analogous to the WRITEBOOT.EXE image on existing OpenVMS VAX andOpenVMS Alpha systems.

EFor information on CD and DVD optical media drives on OpenVMS, pleasexsee Section 14.29. For additional related information on creating?bootable OpenVMS media, please see Ask The Wizard topic (9820).j

9.8 What I/O transfer size limits exist in OpenVMS?



GThe maximum transfer size is an attribute of the particular I/O device,Econtroller and driver combination; there is no inherent limit imposedEby OpenVMS (other than the fact that, today, byte counts and LBNs aregenerally limited to 32 bits).

CThe maximum size of a device I/O request is limited by the value inAUCB$L_MAXBCNT, which is set by the device driver based on variousCfactors. (Also check the setting of the MAXBUF system parameter for6buffered I/O transfers, and check the process quotas.)

DCurrently, SCSI drivers limit I/O transfers to FE00(16) bytes, 65024Bbytes (decimal). The reasons for this transfer size limitation areClargely historical. Similarly, DSSI devices are limited to the sameCvalue, this for hardware-specific reasons. Transfers to HSC and HSJDdevice controllers via the CI are limited to 1,048,576 bytes. ClientDMSCP-served devices are limited to 65535 bytes---to help ensure thatEthe I/O fragmentation processing happens on the client and not on theserver system.

CParts of the OpenVMS I/O subsystem are optimized for data transfers;less than 64KB, because (obviously) most I/O operations areG(substantially) less than that. OpenVMS can handle larger transfers, if(the driver and the device can handle it.

Also see Section 9.4, Section 9.5.o

9.9 Can I use ODBC to connect to OpenVMS database files?



CYes, you can use various available third-party packages that permit>remote ODBC clients to access RMS files and various commercialdatabases via the network.

>For RMS, consider acquiring one of the packages available fromDEasySoft, Attunity Connect (formerly known as ISG Navigator), OracleC(DB Integrator), SolutionsIQ, OpenLink Software (OpenLink UniversalData Access), and Synergex.

The unixODBCI package available at http://www.unixodbc.org 8has variously been found to operate on OpenVMS, as well.

FFor specific commercial databases (other than RMS, of course), contact,the database vendor directly for assistance.w

9.10 If my disks are shown as VIOC Compatible, am I using XFC?



Yes, you are using XFC caching.

CDisks that are using XFC caching use communication and coordination9protocols that are compatible with the older VIOC cachingFimplementation. With the initial implementation of XFC on OpenVMS, youFcan use the command SHOW MEMORY/CACHE to see no disks reported in full XFC mode;Call disks shown will be listed in "VIOC Compatable Mode".

CIf you have the OpenVMS system parameter VCC_FLAGS set to 2 and areDusing OpenVMS Alpha V7.3-1 or later, or are using OpenVMS Alpha V7.3Ewith the VMS73_XFC V2.0 ECO kit or later or with the UPDATE kits, youare using XFC.

EAnother confusion: the XFC product version is and remains V1.0 in allGreleased configurations, please do not confuse the internal XFC product?version (displayed by various commands) with the version number@associated with the various ECO kit(s). XFC V1.0 does not permitDvolumes to enter full XFC caching, as displayed by the "Vols inFull XFC mode"5 portion of the DCL command SHOW MEMORY/CACHE output.o

9.11 RMS Sequential Files and Platform Portability?



CWhen working with mixed platforms, you will want to become familiarGwith the various RMS sequential record formats, including Variable withBFixed Control (VFC), stream, stream LF, and stream CR, among otherrecord formats.

ESwitching formats uses CONVERT/FDL or SET FILE/ATTRIBUTES. The formerBconverts files, the latter resets attributes. Text editors tend toBselect attributes when creating new files that may or may not meetGrequirements. If the default attributes do not match your requirements,Ecreate a stub file, SET FILE/ATTR, then edit the existing file. (Most6editors will preserve attributes on an existing file.)

@When working with Windows, stream is usually the best choice forEsequential file operations. Stream LF is most commonly used with UNIXDand C applications. Windows and UNIX tend not to be able to directly9read files of "unexpected" sequential RMS record formats.

CVFC is a common OpenVMS format, encoding the record length into theErecord. It is this extra data that can cause corruption-like problemsAwhen viewed without RMS; either directly via $qio or via the fileEsystem API on other operating system platforms. You will want to lookAat the low-level record formats, and at the RMS and the Files and2Applications documentation in the OpenVMS manuals.

GIf transfering through other platforms, use of a current version of ZipPE(with the "-Vv" or "-V" option) and unzip, or use of a BACKUP savesetmBwill contain and maintain the RMS file and record attributes. (ForFBACKUP and its own attributes requirements, see the restoration tool.)

l


iM

Chapter 10
OpenVMS Programming Information


c@

If you are searching for something here, please(consider using the text-format FAQ.

x

10.1 Modular Programming, Facility Prefixes and Symbol Naming?



-CPlease first review the OpenVMS Programming Concepts Manual and thetCGuide to Modular Programming manuals. Both are available within thenDOpenVMS documentation set, and provide details of the expected normsfor OpenVMS programs.n

    G
  • Learn about the facility prefix, and use a the appropriate prefixsG uniformly throughout all external symbols, all logical names, and alldD files located in shared directories. The prefix and the use of theG dollar sign ([]$) and the underscore ([]_) help-A avoid collisions with other products. Use of the dollar sign isS" reserved to registered products.H
  • Please consider use of tools such as the Freeware SDL package, andI the GNM package. These permit you to generate include files and messageiH documentation akin to that of OpenVMS, providing users of your product with a familiar environment.F
  • For product installations, consider use of the PCSI installationC utility, and provide a product-specific configuration DCL commandcG procedure (usually SYS$MANAGER:prefix$CONFIG.COM) if configuration is> required./
  • The product startup file is usually namedmF SYS$STARTUP:prefix$STARTUP.COM, and the shutdown file (if needed) is* usually SYS$STARTUP:prefix$SHUTDOWN.COM.


AOpenVMS provides a registry for facility prefixes and for MESSAGE Gmessage compiler codes. To request a prefix and a message facility code8Bfor a product you distributinng to other customer sites, send your&request in a mail message addressed toCproduct[-at-sign-]hylndr.sqp.zko.dec.com, requesting the submission -form and details of the registration process. 

e

/e t i
Note

GPlease do not request facility prefixes for products that local to yourhBbusiness, your site, or your system. Facility prefixes and messageFcodes and the facility registration process are intended solely for HPGproducts and Partner Products (and yes, even OpenVMS Freeware packages)tHthat will be distributed across multiple OpenVMS customer sites.


BFor a list of common coding bugs, please see the remainder of thiszsection of the FAQ and specifically Section 10.22, please also see the@Ask The Wizard topic (1661), and for information on debugging an-OpenVMS application, please see topic (7552)./

l

rGFor additional information on the OpenVMS Ask The Wizard (ATW) area and Afor a pointer to the available ATW Wizard.zip archive, please see"@Section 3.8.k

10.2 Can I have a source code example of calling...?



=GPlease use the available SEARCH command on OpenVMS, and please remember>Fto search the available resources, including the support databases andDthe newsgroup archives. Please also realize that most OpenVMS systemBservices use similar calling sequences, meaning that an example of?calling sys$getjpi can be used as an example for sys$getsyi and">sys$getdvi. Students: please do not expect folks to write your*homework for you. As for search resources:

o

iAOpenVMS programming documentation, including the numerous exampleD@programs found in recent versions of the OpenVMS Programming#Concepts manual, is available: 

d

tDAs for details of argument passing, most OpenVMS system services andARTL routines pass string arguments by descriptor. Languages which(Bsupport native string data types create descriptors automatically;Dthose which do not (eg., C) require that you set them up explicitly.CFor further details on using descriptors and particularly for usingebdescriptors from C, please see Section 10.13.

aFThere is extensive information available on how to call OpenVMS systemEservices and OpenVMS Run-Time Library routines, including examples inr<numerous languages. Among the best available references are:

    !
  • Your language's User Manualo5
  • OpenVMS Programming Environment Manualt2
  • OpenVMS Programming Concepts ManualG
  • OpenVMS Programming Interfaces: Calling a System Routiner'
  • OpenVMS Calling Standardr
r

tBIn addition, you can also locate answers, source code examples andCrelated discussions in the Natural Language Search Assistant (AskQ) database:i

r

CIn this area, you will find the source code of programming examplessBfor calls to many of the OpenVMS system services (and from variousGprogramming languages), including calls to core services sys$getjpi[w],yGsys$getsyi[w] and sys$qio[w], as well as source code examples for callse@to many other system services and run-time library routines, andAexamples of one of the more difficult calling interfaces found on)5OpenVMS systems, that of the smg$create_menu routine.e

eCArne Vajhøj has put together a collection of OpenVMS example programs. It can be found at:s

o

pBAdditional information and examples for OpenVMS are available via:

o

.GFor additional information on the OpenVMS Ask The Wizard (ATW) area and Afor a pointer to the available ATW Wizard.zip archive, please see @Section 3.8.and via:

rm

10.3 How do I get the arguments from the command line?

p

tGIf you're writing a program and want to accept arguments from a foreigndFcommand, you can use LIB$GET_FOREIGN to get the command line and parseDit yourself, or if you're programming in C, use the normal argc/argvmethod.w

-1To write an application which uses the normal DCLnFverb/qualifier/parameter syntax for invocation, see the description ofDthe CLI$ routines in the OpenVMS Callable Utility Routines ReferenceManual.

FIt is possible to write an application which can be used both ways; ifEa DCL verb isn't used to invoke the image, the application parses thetFcommand line itself. One way to do this is to call CLI$GET_VALUE for arequired;parameter. If it is not present (or you get an error), callf@LIB$GET_FOREIGN to get the command line and do the manual parse.

lHSee also Section 8.2.q

10.4 How do I get a formatted error message in a variable?

8

>DUse the SYS$PUTMSG system service with an action routine that storesFthe message line(s) in the variable of your choice. Be sure the action@routine returns a "false" (low bit clear) function value so that SYS$PUTMSGDdoesn't then try to display the message (unless you want it to.) SeeFthe description of $PUTMSG in the System Services Reference Manual for&an example of using an action routine.x

10.5 How do I link against SYS$SYSTEM:SYS.STB on an Alpha system?



lGLINK/SYSEXE is the OpenVMS Alpha equivalent of linking against SYS.STB.l5This links against the base image: SYS$BASE_IMAGE.EXEm

axAlso see Section 10.11, particularly for pointers to the details onxshareable images and shareable image creation, and see Section 10.22>for details of inner-mode floating point requirements, of data?alignment, requirements for use of /NOSYSLIB, and other relatedo|inner-mode programming details, and see Section 10.11 for image-related information.l

10.6 How do I do a SET DEFAULT from inside a program?



9DThe problem is that SYS$SETDDIR only changes the default directory -CNOT the default disk. The default disk is determined by the logicalrGSYS$DISK. If you want to change the default disk within a program, thentEcall LIB$SET_LOGICAL to change the logical SYS$DISK. You will need totEcall both LIB$SET_LOGICAL and SYS$SETDDIR to change both default diskpand the default directory!|

10.7 How do I turn my Fortran COMMON into a shareable image on Alpha?



=AYou need to add SYMBOL_VECTOR=(<common-name>=PSECT) to your6Foptions file. On OpenVMS VAX all OVR/REL/GBL psects were automaticallyCexported into the shareable image's Global Symbol Table. On OpenVMSsEAlpha you have to tell the linker that you want this done by means ofD>the PSECT keyword in the SYMBOL_VECTOR options file statement.

vFThis has several advantages over OpenVMS VAX. First, you don't have toBworry about the address of the psect when you try to create a new,Cupwardly compatible version of the shareable image. Second, you canDcontrol which psects, if any, are made visible outside the shareableimage.

EBy default, COMMON PSECTs in HP Fortran for OpenVMS Alpha (as well assFmost other OpenVMS Alpha compilers) are NOSHR. On VAX, the default wasESHR which required you to change the attribute to NOSHR if you wantedqByour COMMON to be in a shareable image but not write-shared by all;processes on the system. If you do want write-sharing, use:o

o 
<
"
CDEC$ PSECT common-name=SHRs

p


tEin the Fortran source code (the CDEC$ must be begin in column 1) or al@linker options file PSECT_ATTR statement to set the COMMON PSECTattribute to SHR.

S/For further information, see the Linker manual.Q 

r


 i cl n  
PreviousNextContentsIndex

 

X#u6hmble with the older VIOC cachingFimplementation. With the initial implementation of XFC on OpenVMS, youFcan use the command SHOW MEMORY/CACHE to see no disks reported in full XFC mode;Call diskK$WEB3  .2CB(y筗@@ >8.HTML;BEAVIS DISK$WEB3 .2CB(y筗AA ?60.HTML;BEAVIS DISK$WEB3 .2CB(y筗BB >2.HTML;BEAVIS DISK$WEB3 .2CB(y筗CC >4.HTML;BEAVIS DISK$WEB3  .2CB(y筗DD >6.HTML;BEAVIS DISK$WEB3 .2CB(y筗EE >8.HTML;BEAVIS DISK$WEB3 .2CB(y筗FF ?70.HTML;BEAVIS DISK$WEB3 .2CB(y筗GG >2.HTML;BEAVIS DISK$WEB3  .2CB(y筗HH >4.HTML;BEAVIS DISK$WEB3 .2CB(y筗II >6.HTML;BEAVIS DISK$WEB3 .2CB(y筗JJ >8.HTML;BEAVIS DISK$WEB3 .2CB(y筗KK ?80.HTML;BEAVIS DISK$WEB3  .2CB(y筗LL >2.HTML;BEAVIS DISK$WEB3 .2CB(y筗MM >4.HTML;BEAVIS DISK$WEB3 .2CB(y筗NN >8.HTML;BEAVIS DISK$WEB3 .2CB(y筗OO ?90.HTML;BEAVIS DISK$WEB3  .2CB(y筗PP >2.HTML;BEAVIS DISK$WEB3 .2CB(y筗QQ >4.HTML;BEAVIS DISK$WEB3 .2CB(y筗RR >6.HTML;BEAVIS DISK$WEB3 .2CB(y筗A/RQ RR  T0.HTDOCS.WIZARD'WIZ_0498.HTML;BEAVIS DISK$WEB3 .2CB(y筗 @500.HTML;BEAVIS DISK$WEB3 .2CB(y筗 >2.HTML;BEAVIS DISK$WEB3 .2CB(y筗 >4.HTML;BEAVIS DISK$WEB3 .2CB(y筗 >8.HTML;BEAVIS DISK$WEB3 .2CB(y筗 ?10.HTML;BEAVIS DISK$WEB3 .2CB(y筗 >2.HTML;BEAVIS DISK$WEB3 .2CB(y筗 >4.HTML;BEAVIS DISK$WEB3 .2CB(y筗 >6.HTML;BEAVIS DISK$WEB3 .2CB(y筗 >8.HTML;BEAVIS DISK$WEB3 .2CB(y筗 ?22.HTML;BEAVIS DISK$WEB3 .2CB(y筗 >4.HTML;BEAVIS DISK$WEB3  .2CB(y筗 >6.HTML;BEAVIS DISK$WEB3  .2CB(y筗 >8.HTML;BEAVIS DISK$W