home *** CD-ROM | disk | FTP | other *** search
-
- <:=--=:><:=--=:><:=--=:><:=--=:>\|/<:=--=:><:=--=:><:=--=:><:=--=:>
- <:=--=:> <:=--=:>
- <:=--=:> >>>>>=-* Users Guide to VAX/VMS *-=<<<<< <:=--=:>
- <:=--=:> <:=--=:>
- <:=--=:> Part II of III <:=--=:>
- <:=--=:> <:=--=:>
- <:=--=:> Part C: Using the Utilities <:=--=:>
- <:=--=:> Part D: Advanced Guide to VAX/VMS <:=--=:>
- <:=--=:> <:=--=:>
- <:=--=:> By Black Kat <:=--=:>
- <:=--=:> <:=--=:>
- <:=--=:><:=--=:><:=--=:><:=--=:>/|\<:=--=:><:=--=:><:=--=:><:=--=:>
-
- Index
- ~~~~~
- Part C contains information on the following topics:
-
- o Help Utility o Phone Utility
- o Backup Utility o Library Utility
- o Mail Utility o Sort Utility
-
- Part D contains information on the following topics:
-
- o Subprocesses o DECnet
- o Attaching to a Process o Proxy Access
- o Interrupting a Process o Task-to-Task Communication
- o Batch Processing o Remote Printing
- o Controlling Batch Jobs o VAXclusters
-
- <:=- Part C : Using the Utilities -=:>
-
- Help Utility
- ~~~~~~~~~~~~
- The VAX/VMS Help Utility is almost like having a DCL dictionary online. It
- includes an explanation of each DCL command and can optionally explain valid
- command parameters. Help also provides information about other VAX/VMS
- utilities and system services.
-
- There are two modes available for the help utility. If you know the DCL
- command, utility or system service you want more information about, use direct
- mode. If you don't know the command, use query mode. Query mode can also be
- used to see which other commands and other subjects are referenced by the help
- utility.
-
- To use query mode, just type HELP <enter> at the DCL command level. Help will
- display an alphabetical listing of all DCL commands and other topics for which
- information is available and you will be prompted with: "Topic?"
-
- You can exit Help by pressing <enter> or <Ctrl-C> or <Ctrl-Z> or get
- information by typing in the command or subject name followed by <enter>. When
- you request information on a command, Help will display details including how
- the command is invoked, what it does and the default values. Most topics will
- have subtopics available which will be listed alphabetically followed by the
- prompt: "COMMAND-NAME Subtopic?"
-
- You can select subtopic help or press <enter> to return to the "Topic?" prompt.
- If you want to see all the information available on a command, type in "HELP
- command_name ..." or "HELP command_name *".
-
- To use direct mode, enter HELP topic_name <enter>. This will bypass the
- listing of available topic. Additionally, you can enter a valid DCL command
- with or without qualifiers in this mode. For example, to get information on
- the DCL SET command /TERMINAL qualifier, you could enter $ HELP SET TERMINAL.
- The help utility will provide information on the SET/TERMINAL command and
- prompt you for another subtopic since information on other qualifiers is
- available.
-
- For more information and details on the help utility, you can use:
- $ HELP HINTS or $ HELP HELP/INSTRUCTIONS.
-
-
- Backup Utility
- ~~~~~~~~~~~~~~
- The backup utility is usually used by system managers to back up system disks,
- insuring a recent copy of data should the system disks become unreliable.
- Generally, the system disks are backed up to magnetic tape or removable disk
- packs, which are then removed and stored in a save location offline. Users may
- use the backup utility on files in their own accounts to make copies for safe
- keeping, transferring to another system, or for offline storage.
-
- To use the backup utility, you have to decide what you want to back up, and how
- you want it done. You have the following options:
-
- Selective : Files are backed up according to a specified criteria.
- Qualifiers (e.g. /DATE) and file specifications (e.g. *.TXT)
- are used for specifying these criteria.
- File by File: Individual files or entire file directories are backed up.
- Directories are created when copying, unlike the copy command.
- Incremental : Saves file created since the most recent backup. Usually
- performed by system operators.
- Physical : An exact duplicate of a volume is saved. All file structures
- are ignored and the copy is a bit-by-bit duplicate.
- Image : A functionally equivalent copy of the original volume is
- created. Typically done on bootable volumes and system disks.
-
-
- To back up files to a subdirectory: $ BACKUP F1.TXT,F2.TXT,*.DAT [BY.JUNK]
-
- To copy a directory tree: $ BACKUP [dir...]file_spec [dir...]file_spec
-
- To copy disk volumes: $ MOUNT/FOREIGN DJA1:
- $ BACKUP/IMAGE DUA2: DUA1:
-
- To copy to tape: $ INITIALIXE MUA0: TAPE (the first time its used)
- $ MOUNT/FOREIGH MUA0:
- MOUNT-I-MOUNTED, TAPE mounted on __MUA0:
- $ BACKUP [.DRV]MV_DYDRV.MAR MUA0:[]MV_DYDRV.MAR
-
- A save set is a single file containing multiple files that have been backed up.
- To make a save set:
-
- $ MOUNT/FOREIGN MUA0:
- MOUNT-I-MOUNTED, TAPE mounted on __MUA0:
- $ BACKUP DUB1:[BY.JUNK]*.*;* MUA0:08JUN.BAK/SAVE_SET
-
- A single file can be retrieved from a save set by using the /SELECT qualifier.
- For example, to restore the file LOGIN.COM from the previously backed up save
- set:
-
- $ MOUNT/FOREIGH MUA0:
- MOUNT-I-MOUNTED, TAPE mounted on __MUA0:
- $ BACKUP
- __From: MUA0:08:JUN.BAK/SAVE_SET/SELECT=[BY.JUNK]LOGIN.COM
- __To: *.*
-
- Listing a save set: $ MOUNT/FOREIGN MUA0:
- MOUNT-I-MOUNTED, TAPE mounted on __MUA0:
- $ BACKUP/LIST MUA0:08JUN.BAK/SAVE_SET
-
- Selective backups: $ BACKUP *.*/SINCE=12-APR-1988 MUA0:08JUN.BAK/SAVE_SET
- $ BACKUP
- __From: *.*/SINCE=12-APR-1988/EXCLUDE=[*.TMP,*.LOG]
- __To: MUA0:08JUN.BAK/SAVE_SET
-
-
- The following is a list of some other qualifiers you'll find useful.
-
- Qualifier Function
- ~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- /LOG Writes log message to terminal as each backup file is written.
- /VERIFY Verifies the copy or save set with the original after copy.
- /CONFIRM Display each filename and ask for confirmation before copy.
- /DELETE Deletes source file after destination file written.
-
-
- Mail Utility
- ~~~~~~~~~~~~
- When you receive new mail, a message will be sent to your terminal unless the
- /NOBROATCAST qualifier has been specified with the SET TERMINAL command. Mail
- is an interactive utility that understands many commands in a format identical
- to DCL commands. The utility is invoked by typing "$ MAIL" at the DCL command
- level. Mail has a built in help feature which works the same way as the
- VAX/VMS Help Utility. Mail may be sent interactively or directly.
-
- Interactive implies the use of the mail utility in conversational mode by
- invoking mail at the DCL command level. After invoking the mail utility, use
- the SEND command, and mail will prompt you for the name of the user(s) you want
- to send the mail to, your name, the subject, and the message text which you
- will terminate with <Ctrl-Z>. When you press <Ctrl-Z> the message is sent and
- you are returned to the mail prompt where you can type EXIT to quit.
-
- To send mail in direct mode from the DCL command line, use the following
- format: $ MAIL file_spec user /SUBJECT="character string" where "file_spec"
- is a valid VAX/VMS file specification containing the body of your mail message
- and "user" is the name of a user on your local system or remote node. The
- /SUBJECT qualifier is optional.
-
- To send mail to multiple users (like a mailing list) create a file with a list
- of the account names of every user you want to receive the message. Then enter
- @FILENAME at the "To:" prompt and each user listed in the distribution list
- will receive a copy of your mail. A distribution list may also contain another
- distribution list by preceeding the second name with an at sign (@). Comments
- are included by using an exclamation point (!). The following is a sample
- distribution list:
-
- ! VAX.DIS
- !
- ! Staff
- JONES
- OPER
- BYNON
- !
- ! Accounting personnel
- @ACTLIST
-
- To read your mail, just type MAIL <enter> and you will be told how many
- messages you have waiting. Read is the default command, so you can just
- press <enter> to start reading them. To reply to a message, use the REPLY or
- ANSWER commands and the mail utility will fill out the header information
- automatically. You can store your mail in folders for later reference. The
- system has three default folders (MAIL, NEWMAIL, and WASTEBASKET).
-
- MAIL is the default mail folder and always exists. It is used to store mail
- messages after you've read them unless you file these messages in other folders
- you've created.
-
- The NEWMAIL folder stores mail messages before you read them, like a mailbox.
- They're automatically moved to the MAIL folder after you've read them unless
- you specify a different destination folder with the MOVE command.
-
- The WASTEBASKET folder is a temporary folder used to store messages that have
- been deleted. These messages remain in the WASTEBASKET folder until you exit
- the mail utility, at which time they're thrown out permanently.
-
- To create new folders, select a message and enter the MOVE command. If you
- attempt to move a message to a nonexistent folder, you'll be asked if you want
- to create a new folder. For example:
-
- MAIL> 11
- MAIL> MOVE MEMOS
- Folder MEMOS does not exist. Create it (Y/N, default is N)? Y
- MAIL-NEWFOLDER, folder MEMOS created MAIL>
-
- The SELECT command allows you to move from one folder to another. For example,
- if you type SELECT JUNK at the "MAIL>" prompt, you will be moved to the JUNK
- folder, and mail will respond with the number of messages contained in the new
- folder.
-
- The DELETE command accepts a message number as a parameter or deletes the
- current message if a message number is not supplied. To delete a folder, just
- delete all the messages in that folder with the DELETE qualifier /ALL.
-
- To log a mail message to a file, use the EXTRACT qualifier. If the /NOHEADER
- qualifier is used, the header information will not be included. For example:
- EXTRACT/NOHEADER MEMO.TXT will save the currently selected message to a file
- named MEMO.TXT.
-
- For more information on the mail utility, use mail's HELP command.
-
-
- Phone Utility
- ~~~~~~~~~~~~~
- The VAX/VMS Phone Utility allows you to talk to other users on your system. It
- simulates a real telephone with such features as call holding, conference calls
- and telephone directories. The Phone utility only works with VT100, VT200 or
- compatible terminals.
-
- To call someone with the phone utility, enter "$ PHONE username" where username
- is the person you want to talk to. Your screen will split horizontally in half
- and indicate that the phone utility is ringing the other person. Your half of
- the conversation will be displayed on the top of the screen and the other
- person's will appear on the lower half.
-
- The phone utility may also be used interactively by entering "$ PHONE", and you
- will now be given the phone prompt (%). You can enter commands directly now
- (e.g. "% DIRECTORY"). The phone utility has an online help facility just like
- the mail utility.
-
-
- Library Utility
- ~~~~~~~~~~~~~~~
- Sometimes its easier to maintain a single file instead of a group of related
- files. The VAX/VMS Library Utility lets you create and maintain a specially
- formatted file called a library in which you can store groups of single files
- called modules. Predefined libraries include text, help, object, sharable
- image and macro. Many VAX/VMS utilities such as HELP and LINK are capable of
- processing library files. Unless you're a programmer or system manager,
- you'll probably only use text and help libraries.
-
- To create a library use the LIBRARY command's /type qualifier and the /CREATE
- qualifier. The /type qualifiers are: /TEXT, /SHARE, /HELP, /OBJECT, /MACRO.
- For example to create a text library named BOOK.TLB:
-
- $ LIBRARY/TEXT/CREATE BOOK.
-
- You may optionally specify a list of files to be included in a library when it
- is created. For example:
-
- $ LIBRARY/TEXT/CREATE BOOK TOC,C1,C2,INDEX
-
- To list the names of modules in a library, use the /LIST qualifier:
-
- $ LIBRARY/TEXT/LIST BOOK
- Directory of TEXT library BOOK.TLB;1 on 12-JUN-1989 14:12:07
- TOC
- C1
- C2
- INDEX
-
- You can also display a history of updates made to the library by using the
- /HISTORY qualifier with the /LIST qualifier.
-
- To add modules to an existing library, use the /INSERT qualifier:
-
- $ LIBRARY/TEXT/INSERT BOOK CH3
-
- To update a module in a library, do the following:
-
- o Extract the module to be updated with the /EXTRACT qualifier.
- o Make the necessary changes.
- o Write over the old module with the /REPLACE qualifier.
-
- For example: $ LIBRARY/TEXT/EXTRACT BOOK CH2
- $ EDIT CHAP2.TXT
- .
- . (edit the file)
- .
- $ LIBRARY/TEXT/REPLACE BOOK CH2
-
-
- Sort Utility
- ~~~~~~~~~~~~
- The VAX/VMS Sort Utility will reorganize records within a file. The simplest
- form of the sort command will organize records in ascending alphabetical order.
- For example, to sort BOOK.TXT, you could issue the command:
-
- $ SORT BOOK.TXT SORTED.TXT
-
- The Sort utility sorts on the first character of the field in each record in
- the input file. If there is more than one field or column in a record, the
- entire record is ordered, not just the first field.
-
- Here's an example of sorting in descending order numerically with multiple
- fields. The sample data file JUNK.TXT contains two fields of data. The first
- field contains a name, and the second field, starting in column 9 contains the
- two-digit number we're sorting by:
-
- PAT 47
- PAT 47
- JIM 09
- TOM 23
- RICH 43
- GARY 02
- KURT 13
- KEVIN 27
-
- Sort the file: $ SORT/KEY=(POSITION=9,SIZE=2,DESCENDING) JUNK.TXT SORTED.TXT
-
- The sorted file (SORTED.TXT) will now look like this:
-
- PAT 47
- RICH 43
- KEVIN 27
- TOM 23
- KURT 13
- JIM 09
- GARY 02
-
-
- <:=- Part D : Advanced Guide to VAX/VMS -=:>
-
- Subprocesses
- ~~~~~~~~~~~~
- A major benefit of the VAX/VMS operating system is its support of multi-
- processing. This is not restricted to multiple users logged into different
- terminals however. VAX/VMS users may create multiple processes known as
- subprocesses from within their main processes.
-
- The DCL SPAWN command is used to create a subprocess. The SPAWN command will
- create a subprocess with the attributes (default directory, privileges, memory,
- etc.) of its parent process unless otherwise specified. For example:
-
- $ SPAWN
- % DCL-S-SPAWNED, process BYNON_1 spawned
- % DCL-S-ATTACHED, terminal now attached to process BYNON_1
-
- In this case, the parent process is put into hibernation, the subprocess is
- given control of the keyboard, and we are left at the DCL prompt. You can now
- enter any DCL commands, utilities, or other programs. To return to the parent
- process, just $ LOGOUT of the subprocess:
-
- $ LOGOUT
- Process BYNON_1 logged out at 12-JUL-1981 13:04:17.10
- $ DCL-S-RETURNED, control returned to process BYNON
-
- The SPAWN qualifier /NOLOG can be used to suppress the informational messages
- generated when a subprocess is created or logged out. DCL Commands, procedures
- and VAX/VMS images (utilities and programs) may be executed directly with SPAWN
- by entering the correct syntax for the command or procedure after the SPAWN
- command. For example: $ SPAWN/NOLOG MAIL
-
- If you have a task that can execute without user intervention (e.g. a program
- compiler), you can spawn a task to run as a background process to your current
- process. For example: $ SPAWN/NOWAIT FORTRAN VAXBBS
-
- The SPAWN qualifier /NOWAIT spawns the task to run concurrently (parallel) to
- the parent process. Both processes will share the terminal and any messages
- >from the background task will be displayed at the terminal. To avoid possible
- conflicts, use the /OUTPUT qualifier:
-
- $ SPAWN/NOWAIT/OUTPUT=COMPILE.LOG FORTRAN.VAXBBS
-
- When the job in the subprocess is complete it will terminate and be removed
- >from the system.
-
-
- ATTACHing to a Process
- ~~~~~~~~~~~~~~~~~~~~~~
- You can use the DCL ATTACH command to connect your keyboard to any process or
- subprocess you've created. To exit from BYNON_1 back to BYNON with the ATTACH
- command, enter "$ ATTACH BYNON" and the subprocess hibernates while you are
- returned to the parent process.
-
-
- Interrupting a Process
- ~~~~~~~~~~~~~~~~~~~~~~
- You can interrupt a process at anytime to create a subprocess by pressing
- <Ctrl-Y> and then using the SPAWN command. When you're done working with the
- subprocess and have returned to the interrupted process, type CONTINUE to start
- processing again where you left off. Some VAX/VMS utilities, such as MAIL,
- support SPAWN intrinsically, so you can spawn a process within these utilities
- by entering the SPAWN command without pressing <Ctrl-Y> first.
-
-
- Batch Processing
- ~~~~~~~~~~~~~~~~
- The SUBMIT command was briefly discussed in Part II: Programming the VAX. A
- batch job is one or more DCL command procedures that execute from a detached
- process with your privileges and quotas. The controller of the process is the
- batch queue which accepts jobs via the SUBMIT command. Batch jobs execute
- without user interaction, permitting you to use your terminal for interactive
- work while the system executes the batch job (command procedure). Batch jobs
- are used to execute tasks that take a long time to run, use many system
- resources, or need to be scheduled to execute at a specific time.
-
- The SUBMIT command will enter a command procedure to the default batch queue
- (SYS$BATCH) if a specific queue is not provided. A command procedure submitted
- for batch execution is given a job name which defaults to the command procedure
- name unless otherwise specified. The entry number given to the job is used to
- control it (delete, rename, etc.)
-
-
- Controlling Batch Jobs
- ~~~~~~~~~~~~~~~~~~~~~~
- You can specify a name for a batch job with the /NAME qualifier:
-
- $ SUBMIT BACKUP /NAME=DAILY_BACK
-
- You may also execute more than one command procedure by separating the
- procedure names with a comma:
-
- $ SUMBIT SORT_DATA,REPORT /NAME=WEEKLY_REPORT
-
- To schedule a batch job to execute after a specific time:
-
- $ SUMBIT CLEANUP /AFTER=11:40
- Job CLEANUP (queue SYS$BATCH, entry 39) holding until 1-JUN-1989 11:40
-
- To hold a job in the queue to be released later:
-
- $ SUMBIT REMINDER /HOLD
- Job REMINDER (queue SYS$BATCH, entry 12) holding
- $
- $ SET QUEUE/ENTRY=32/RELEASE SYS$BATCH
-
- To submit a job to a different queue: $ SUBMIT TESTJOB /QUEUE=SLOW
-
- To lower the priority (e.g. if it's CPU intensive):
-
- $ SUBMIT CRUNCH /PRIORITY=2
-
- To pass parameters: $ SUBMIT COMPILE / PARAMETERS=(WINDOWS,MISC,DISP_IO)
-
- To disable the automatic printing of the batch job's log (file instead):
-
- $ SUBMIT GOJOB /NOPRINT /LOG_FILE=DUA2:[BYNON]
-
- This will create a file DUA2:[BYNON]GOJOB.LOG. If the /NOPRINT qualifier is
- not specified, the log file will be printed and deleted. To print and keep the
- log file, use the /KEEP qualifier with the /LOG_FILE qualifier.
-
- After you submit a procedure to a batch queue, you can monitor its status and
- job characteristics by using the SHOW QUEUE command. This will display the
- name, entry number and status of all the jobs you have in queue. The /ALL
- qualifier will display all jobs you have enough privilege to see, and the /FULL
- qualifier provides more information about jobs, such as operating
- characteristics and submission time.
-
- You can use the SET QUEUE/ENTRY command to modify a job's priority
- (/PRIORITY), name (/NAME), or status (/RELEASE or /AFTER). For example:
-
- $ SET QUEUE /ENTRY=217 /PRIORITY=2 SYS$BATCH
-
- Use the DELETE /ENTRY command to delete jobs: $ DELETE /ENTRY=18 SYS$BATCH
-
-
- Using DECnet
- ~~~~~~~~~~~~
- DECnet uses the standard VAX/VMS file specifications for remote file access.
- In addition to a node specification, you may also include access control
- information (username and password) in quotes. For example:
-
- BURG"JONES MYPW"::DUA2:JUNK.TXT
- | | | | |
- | | | | +---- Filename.Extension
- | | | |
- | | | +---------- Device name
- | | |
- | | +------------------ Password
- | |
- | +----------------------- Username
- |
- +----------------------------- Node name
-
- Unless a specific DECnet account exists on the host node, or proxy exists, you
- must supply access control information to execute a command on a remote system.
- (e.g. $ TYPE BURG""JONES MYPW"::DUA2:JUNK.TXT)
-
-
- Proxy Access
- ~~~~~~~~~~~~
- Because including access control information in a command string is a security
- risk, Digital provides proxy access, which works by keeping a database of users
- and hosts who may gain access to the system via DECnet. The format of the
- database is: SYSTEM::REMOTE_USERNAME LOCAL_USERNAME.
-
-
- Task-to-Task Communication
- ~~~~~~~~~~~~~~~~~~~~~~~~~~
- This is a feature of DECnet which allows programs on one system to communicate
- with programs on another (e.g. the DCL TYPE command) To execute a procedure on
- a remote system, use the TYPE command with the TASK=xxx parameter. For
- example:
-
- $ TYPE VAX1::"TASK=SHOW_USERS"
-
- To show the users on a remote system you would write a command procedure
- something like this:
-
- $! Show_Users.Com
- $!
- $ IF FMODE() .EQS. "NETWORK" THEN GOTO NETWORK
- $ SHOW USERS
- $ EXIT
- $ NETWORK:
- $ DEFINE/USER_MODE SYS$OUTPUT SYS$NET
- $ SHOW USERS
- $ EXIT
-
- Since SYS$OUTPUT is redirected to SYS$NET, the output is redirected to your
- terminal over DECnet. Task-to-Task communication can be simple (like
- Show_Users) or complicated (like programs passing data back and forth).
-
-
- Remote Printing
- ~~~~~~~~~~~~~~~
- If your DECnet network contains a LAN such as Ethernet, you'll probably have to
- share printers with other nodes on the network. The easiest way to print a
- file is to copy it directly to the print device. This works fine as long as
- the device is spooled and set up with world write privileges. For example: $
- COPY JUNK.TXT BURG::LCA0: will copy the file JUNK.TXT to the device LCA0: on
- node BURG.
-
- Another way to print is to use the DCL PRINT/REMOTE command. However, the file
- must be located on the remote system to use this, which is inconvenient if the
- file you're printing is on the local system. You can still do it though:
-
- $ COPY JUNK.TXT BURG::[BYNON]
- $ PRINT /REMOTE BURG::[BYNON]JUNK.TXT
- Job JUNK (queue SYS$PRINT, entry 512) started on LCA0
- $ DELETE BURG::[BYNON]JUNK.TXT
-
- VAXclusters
- ~~~~~~~~~~~
- The main purpose of a VAXcluster is high processor ability, shared resources,
- and a single security and management area. There are two basic type of
- VAXclusters, heterogeneous and homogeneous, but a mix of the two is possible.
- The main difference between these types is how they share resources,
- specifically the VAX/VMS OS environment.
-
- The VAX/VMS OS environment is identical on each cluster in a homogeneous
- VAXcluster. This is done by using a common system disk for all the nodes.
- User accounts, system files, queues and storage devices are shared, and all of
- the computers behave the same way.
-
- In a heterogeneous VAXcluster, the environment on each system is different.
- Each VAX has its own system disk, user accounts and system files. Queues and
- storage devices may or may not be shared. Users can work in different
- operating environments, depending on the system they're using.
-
- Usually a VAXcluster is accessed by an Ethernet-based terminal server. Using
- a terminal server, a user can establish a session with any VAXcluster member,
- and the connection is identical to that of a directly connected terminal.
- However, terminal sessions can support multiple simultaneous sessions to
- different nodes. In the unlikely event that a VAXcluster is set up with
- directly connected terminals and you need to access a different system, you
- can DECnet via the SET HOST facility. All VAXcluster systems support DECnet
- within the cluster.
-
- VAXcluster members (nodes) often share processing resources through the use
- of print and batch queues known as cluster-wide queues, which are used the
- same as a normal queue. The only extra information you need is the queue
- name. A list of all the queues in a cluster can be called up with the DCL
- SHOW QUEUE command. If you submit a job to a cluster-wide queue, you must
- insure that the node on which it resides has access to the file you want to
- print or the command procedure you want processed.
-
-