1 ACCRPTGEN
 Generates accounting report summaries.  The command format is:

 @SYS$MGR_UTIL:ACCRPTGEN  [file_spec]  [out_dd]  [type]  [opsys_flag]

 where the file_spec parameter names the input accounting file
 (if not given, SYS$MANAGER:ACCOUNTNG.OLD is used for defaults).
 The out_dd parameter specifies the output device and directory while
 the type parameter is the file type for the output reports.  If the
 output device/directory is not specified, SYS$DISK:[] is used while
 the default output file type is ".LIS".

 The opsys_flag parameter is TRUE if being run on the Operational
 VAX System (some reports not made and none are queued for printing).
 If opsys_flag is not given, then it is assumed that the procedure
 is being run on the Development system.  The opsys_flag controls
 the printing of the reports and the title ("Operational System" or
 "Development System").

1 ACNETSTS
 Create a new version of the ACNETSTS.HLB help library (for the
 ERRHELP command) using the RUNOFF sources in [SYSHLP.ACNETSTS]
 (under SYS$SYSROOT:).  Optionally (if a file specification is given),
 copy the new version of a RUNOFF source file to the [.ACNETSTS]
 area before beginning the rebuild:

	@FERMI$LIB:ACNETSTS  [file]

 where if the file parameter is non-null, the file is copied to
 the source area.

 You must have either the SYSPRV or SETPRV privilege.

1 ADDUSER
 To add one or more new user accounts, do:

	@SYS$MGR_UTIL:ADDUSER

 this can only be done from a privileged account (usually done from
 SYSMANAGER).  The ACCOUNTS batch job is submitted before the
 procedure exits to update the additional user information (kept
 outside the UAF) and to generate any required reports.

1 BATQUEDEL

	SYS$MGR_UTIL:@BATQUEDEL   jobname

 Deletes all jobs in SYS$BATCH queue with the given job name
 (P1 parameter).  If no parameter value is given, the procedure
 exits without doing anything.  Otherwise all jobs with the
 specified name in the batch queues AND in the pending (AFTER) or
 holding (HOLD) state are deleted.  Any current jobs are allowed
 to continue running.  If any job so deleted was waiting state until
 a specified time, the absolute time (date, hour and minutes) is
 then returned in the global symbol JOB_TIME.  If no job in such
 a state is found then JOB_TIME is returned as a null string.  If
 more than one job is held, the JOB_TIME returned is for the last
 job in the queue.

1 CHANGEUIC
 This command procedure is used to change a user's UIC (include the
 ownership of his files).  The command format is:

	@SYS$MGR_UTIL:CHANGEUIC  username  newuic

 The user's name and his new UIC are entered as parameters or will be
 prompted for.  The user's file quota on his default disk is automatically
 assigned to his new UIC and the ownership of the files in the user's
 default directory (and its subdirectories) is changed to the new UIC.
 The quota associated with the old UIC is removed.

1 CHGOWNERS
 Searchs for all files owner by a particular UIC and then changes
 the owner of that file to a new UIC.  The format of the command is:

	@SYS$MGR_UTIL:CHGOWNERS  old_uic  user_or_uic  [device[:]]

 All files in all directories on the disk (current default device
 used if no device specified) are scanned for the particular owner
 UIC specified.  The current file owner must be given by the old_uic
 parameter in the format "[ggg,mmm]".  The new file owner (via the
 user_or_uic parameter) be given as the user name or as a UIC (in
 which case, the UIC must be in the format "[ggg,mmm]").
 BYPASS (or SETPRV) privilege is required to use this command
 procedure.

1 DISKQUOTA
 The DISKQUOTA command procedure will create a command file to
 restore the current disk quota settings (using the DISKQUOTA program).
 Execute the command procedure by doing:

	@SYS$MGR_UTIL:DISKQUOTA  device[:]  [file_spec]

 The output file specification defaults are taken from
 SYS$DISK:QUOTAS.COM.

1 DISKUSAGE
 The DISKUSAGE command procedure prepares a report on the current disk
 space usage.  To use this procedure, enter the command:

	@SYS$MGR_UTIL:DISKUSAGE  device[:]  [report]

 This procedure is dependent upon the format of the output from the
 DISKQUOTA and WHO programs.

1 ERRLOGJOB
 Batch job to dump error log every third day at 06:30 AM.  To submit
 the ERRLOG batch job, use the command:

	@SYS$MGR_UTIL:ERRLOGJOB  action

 where the action parameter determines when the job will be run:

   SETUP     setup job to run 3 days from current day or, if currently
             there is an ERRLOG job in the batch queue then re-submit
             the job to run at the time that job would have been run.

   TOMORROW  setup ERRLOG to run tomorrow morning and every 3 days
             thereafter.

   NOW       execute ERRLOG job immediately and every 3 days starting
             with today.
   
2 ONCEONLY
 The ERRLOG job may be run immediately and only a single time (no
 re-submittal for 3 days hence) by doing:

	$ SUBMIT SYS$MGR_UTIL:ERRLOGJOB/PARAMETER=ONCEONLY

 or the error log may be dumped in the context of the current
 process by doing:

	@SYS$MGR_UTIL:ERRLOGJOB ONCEONLY


1 ERRLOGSAV
 Batch job or command procedure to save the old error log files
 (ERRLOG.OLD;* in SYS$ERRORLOG:) onto magnetic tape.  The format
 of the command is:

	@SYS$MGR_UTIL:ERRLOGSAV  [all]  [init]

 If the all parameter is the literal "ALL", then all the ERRLOG.OLD
 files are saved.  Normally the oldest version of these files (one
 with the minimum version number) is a dummy file to hold the version
 number.  If the init parameter is the literal "INIT" then the save
 tape is initialized with volume label ERRLOG before the files are
 saved.  After the files have been copied to tape and deleted from
 SYS$ERRORLOG:, then an empty (dummy) ERRLOG.OLD file is created with
 the maximum version number from the previous set of ERRLOG.OLD files.

1 FINDAPID
 Return the process id of an already existing process given the name
 (and optionally the group) for the process:

	@SYS$MGR_UTIL:FINDAPID  prcnam  [grp]

 Returns the global symbol FIND_A_PID set to the process id (same format
 as used in F$GETJPI) of the existing process with the given name.  If
 no process is found then the null string is returned in FIND_A_PID.

 If the group number (optionally given by "grp") is not specified, the
 group number from the current UIC is used.  The process id returned will
 be for the process with the given name for the specified group.  If the
 group number is specified (explicitly) as 0, then the first process
 found (in any group) with the given name will have its pid returned.
 You should have GROUP or WORLD privilege to really use this procedure.

1 FILOWNERS
 Generates a list of all files owned by a particular user on a
 specified disk.  The format of the command is:

	@SYS$MGR_UTIL:FILOWNERS  user_or_uic  [device[:]]

 All files in all directories on the disk (current default device
 used if no device specified) are scanned for the particular owner
 UIC specified.  The file owner may be given via the user name or
 as a UIC (in which case, the UIC must be in the format "[ggg,mmm]").
 BYPASS (or SETPRV) privilege is required to use this command
 procedure.

1 FNDSAVFIL
 This command procedure is invoked as:

	@SYS$MGR_UTIL:FNDSAVFIL  disk  select

 to search for occurrences of the selected file(s) in the current backup
 tape set journal files.
2 Disk
 The disk name under which the file is to be searched can be given
 by the logical name (such as "USR$DISK1:") or by the keyword
 "USERn" (where "USER1" specifies "USRDISK1", the same as if the
 "USR$DISK1:" logical name were used).  The keyword "SYSTEM" is used
 to specify the system disk.
2 Select
 The select parameter becomes the value of the /SELECT qualifier
 of the BACKUP/LIST command.  One or more file specifications may
 be listed (separated by commas).  The file specifications may
 include a directory specification (with or without wild cards) but
 must not include any device specifications.

! Editted for V2.0 of GETUAF at Fermilab, Frank J. Nagy  04-Apr-83
!
1 GETUAF
 The function of this program is to fetch information from the System
 User Authorization File.  The access key may be either a username or a
 UIC (for multiply-defined UIC's only the first user record is returned).

 Calling Procedure:

    $ GETUAF :== $FERMI$EXE:GETUAF
    $ GETUAF access_key

 This program requires suitable privilege to access the system User
 Authorization File (SYSPRV).

2 Parameter
 access_key
    This is the 'username' or the '[uic]' of the UAF record that
    is desired.  If it is the '[uic]' it must be enclosed in []
    to distinguish it from a 'username'.

    If the '[uic]' specified has more that one record associated
    with it only the information on the first record found is
    returned.

2 Qualifiers
/ACCOUNT=symbol
 will return the account name from the record, selected by the
 access_key, in the local 'symbol' supplied.

/CTRLY=symbol
 will return "NO" if Control-Y is disabled for the account at login
 (the DISCTLY flag is set), otherwise "YES" will be returned in the
 local 'symbol' supplied.

/CAPTIVE=symbol
 will return "YES" if this is a captive (or turnkey) account
 (the CAPTIVE flag is set), otherwise "NO" will be returned in the
 local 'symbol' supplied.

/DEVICE=symbol
 will return the default disk device from the record, selected by
 the access_key, in the local 'symbol' supplied.

/DIRECTORY=symbol
 will return the default directory from the record, selected by the
 access_key, in the local 'symbol' supplied.

/DISUSER=symbol
 will return "YES" if this account is disabled from interactive
 logins (the DISUSER flag is set) in the local 'symbol' supplied.
 Normally, "NO" will be returned for an "enabled" account.

/EXACT (D)
/NOEXACT
 This qualifier specifies whether the username access_key specified 
 is to match the name of a user in the User Authorization File 
 exactly or if only the leading characters specified need match.

 If /NOEXACT is specified then the access_key need only match the 
 leading characters of the record key.  This is useful in 
 determining if a potential username to be added to the UAF will 
 generate a directory name which matches an existing directory on 
 the system.  The /NOEXACT will only return the first match.

 The default is /EXACT.

/NEWMAIL=symbol
 will return "YES" if "New Mail" messages are to be generated for
 for the account at login.  Otherwise, (if the DISNEWMAIL flag is
 is set) "NO" is returned in the local 'symbol' supplied.

/NEXT_UIC_MEMBER=symbol
 will return the next available (un-used) member number (in octal).
 The group and the lower limit for the search are specified by the
 access_key which must be a UIC specification when this qualifier is
 specified.

 An error will be generated if any of /USERNAME, /UIC, /ACCOUNT,
 /DEVICE, /DIRECTORY, /OWNER, /CTRLY, /CAPTIVE, /DISUSER, /NEWMAIL
 or /WELCOME are specified along with this qualifier.

/OWNER=symbol
 will return the owner name from the record, selected by the
 access_key, in the local 'symbol' supplied.

/UAF=file_spec
 This qualifier will specify then name of an alternate User 
 Authorization File.

 By default the program will translate the logical name SYSUAF and
 append the translated value to SYS$SYSTEM: to find the User
 Authorization File. 

/UIC=symbol
 will return the UIC from the record, selected by the access_key, in
 the local 'symbol' supplied.  The UIC is returned in the format
 "[ggg,mmm]".

/USERNAME=symbol
 will return the username from the record, selected by the
 access_key, in the local 'symbol' supplied.

/WELCOME=symbol
 will return "YES" if welcoming messages are to be displayed
 for the account at login.  Otherwise, (if the DISWELCOM flag
 is set) "NO" is returned in the local 'symbol' supplied.

1 LPADOWN
 This command procedure is invoked as:

	@SYS$MGR_UTIL:LPADOWN  DOWN

 when the LPA0: line printer is down.  This switches a printing to
 the LPB0: line printer.  The command:

	@SYS$MGR_UTIL:LPADOWN  RESTORE
	-or-
	@SYS$MGR_UTIL:LPADOWN  UP

 will restore conditions for normal operation (generic print files
 output to LPA0: only).

1 LPBQUEASS
 This command procedure is used to change the assignment of logical
 queues LXY and NARROW to printer LPB0:.  The command format is:

 	@SYS$MGR_UTIL:LPBQUEASS  [queue]

 The procedure always assumes that the "other" queue is currently
 active on LPB0:, where the queue argument gives the name of the
 new queue to assign to LPB0:.  The argument must name one of the
 logical queues LXY (default case) or NARROW.  Normal operation
 has logical queue LXY assigned to LPB0:.

1 MODSQUOTA
 This command procedure will display or modify a user's disk quota
 keying on the user's name rather than his UIC.  The command format
 is:

	@SYS$MGR_UTIL:MODSQUOTA  username  [newquota]  [newover]

 If the newquota parameter is not specified, then the current quotas
 for the user are just displayed.  The quota displayed or modified
 is for the users DEFAULT device!  Must have SYSPRV to use this
 procedure to modify a quota.

1 MOVACCRPT
 Moves accounting or monitoring reports from the Operational Vax to the
 Development Vax for printing.  The format of the command is:

	@SYS$MGR_UTIL:MOVACCRPT  type

 The SLAVEVAX command must be executed on the Operational VAX to invoke
 the TIA VAX-to-VAX file transfer command procedures.
2 Parameters
 The type parameter selects the report type to be transferred and printed:

	MON   monthly accounting reports
	WKY   weekly accounting monitor reports


1 MOVUSEPTS
 Moves system usage monitoring reports from the Operational Vax to the
 Development Vax for printing.  The format of the command is:

	@SYS$MGR_UTIL:MOVUSEPRT  [list]

 The SLAVEVAX command must be executed on the Operational VAX to invoke
 the TIA VAX-to-VAX file transfer command procedures.
2 Parameters
 For usage reports, the list parameter specifies which days reports are to
 be copied.  The list parameter may take one of the following forms:

	""    (null) previous day's report (i.e. SUNDAY if today is Monday)
      *     full week's reports (MONDAY through following SUNDAY).
	.     partial week's (from MONDAY through to yesterday).
	ALL   same as "*".
	LAST  previous week's reports (full week).
	-1    same as "LAST".
	
 Or the list parameter may be a list of the days whose reports are to be
 copied.  Only the first 3 letters of the day are needed (thus MON, TUE
 WED, THU, FRI, SAT, and SUN can be used).

1 NEWOWNER
 Procedure to change the owner UIC of all files in a complete
 subdirectory tree beneath one or more UFD's.  The UIC's are
 set to that of the owner of the UFD-level directory and propagated
 on down the directory tree.

 To change the owner of a single directory tree:

	@SYS$MGR_UTIL:NEWOWNER  dev:  directory

 To change the owner of all files on the volume:

	@SYS$MGR_UTIL:NEWOWNER  dev:  *

 The directory parameter may or may not be enclosed in brackets [].

1 ONLBAKDSK
 Perform an online backup of a disk volume to another disk
 such that the output disk could be used to replace the original
 disk (assuming removeable media drives).  This procedure will
 use BACKUP/IMAGE to perform the file copy operation in order to
 preserve the original directory structures and file contents. To
 use the procedure do:

	@SYS$MGR_UTIL:ONLBAKDSK  log_name

 log_name is the logical name of the disk device to be backed up.

1 ONLBAKFUL
 Perform an online backup of a disk volume to magnetic tape by
 saving the information needed to reconstruct the entire disk
 and file contents.  This procedure will use BACKUP/IMAGE to
 perform the file copy operation in order to preserve the original
 directory structures and file contents. To use the procedure do:

	@SYS$MGR_UTIL:ONLBAKFUL  log_name  [single]

 log_name is the logical name of the disk device to be backed up.
 If single is the literal "SINGLETAPE" then only a single magtape
 drive will be used for the output volumes.

1 PRIJOBREL
 Release a print job being held from printing (was submitted with
 the /HOLD qualifier) using the print job's name:

 	@SYS$MGR_UTIL:PRIJOBREL  jobname  [queue-name]

 Releases all jobs in the named queue with the given job name.
 If no job name is given, the procedure exits without doing anything.
 Otherwise all jobs with the specified name in the print queue AND
 in the HOLD state are released.   Any CURRent jobs are allowed to
 to continue printing.  If no queue name is given, then SYS$PRINT
 is assumed by default.

1 PRIQUEDEL
 Delete a print job waiting in the print queue using the job's name:

 	@SYS$MGR_UTIL:PRIQUEDEL  jobname  [queue-name]

 Releases all jobs in the named queue with the given job name.
 If no job name is given, the procedure exits without doing anything.
 Otherwise all jobs with the specified name in the print queue AND
 in the HOLD or AFTER state are deleted.  Any CURRent jobs are allowed to
 to continue printing.  If no queue name is given, then SYS$PRINT
 is assumed by default.

1 SYSDMPJOB
 Batch job to run SDA on the system dump file and copy the system
 dump file to magnetic tape (volume SYSDMP).  This batch job is
 normally submitted as part of the system startup but may be
 manually invoked via:

	$ SUBMIT/NOPRINT  SYS$MGR_UTIL:SYSDMPJOB/PARAMETER=MANUAL

 The normal testing (using TSTSYSDMP.EXE) of the system dump file
 for Operator requested shutdown or already-processed (by SDA)
 status is skipped in MANUAL mode.

1 UFDOWNER
 This command procedure allows the system manager to change the
 owner UIC of a User File Directory (UFD, the next level below the
 MFD).  The procedure is called by:

	@SYS$MGR_UTIL:UFDOWNER   device  directory  {username}

 Where the username argument is required only if different (for
 instance, is longer than 9 characters) than the directory name.
 The UFD must be on the current default disk (SYS$DISK:).  The
 directory name can be entered without being enclosed in brackets 
 (i.e., "xx" rather than "[xx]").

 An alternate calling sequence for the procedure is:

	@SYS$MGR_UTIL:UFDOWNER  device  directory  [ggg,mmm]

 where "[ggg,mmm]" represents the UIC which is to be the new owner
 UIC of the UFD.

 The process must have SYSPRV to use this procedure.  Also, this 
 procedure only changes the owner of the UFD, the ownership of the
 remainder of the directory tree must be modified using the
 NEWOWNER command procedure.

1 DELTREE
 Delete a complete directory tree.

	@FERMI$EXE:DELTREE  root

 where root is the pathname of the root of the tree to delete.  All
 the files and directories, including the named root, are deleted.

1 EDITSET
 Perform a set of edits (using EDT) on several files, applying the
 same edits to each file.

	EDITSET  [file-spec(s)]

 A file spec or list of file specs (including wild cards if desired)
 are to be entered on the command line.  If none are not entered, they
 are prompted for by "Files:".  The edit commands are then prompted for
 by the prompt "Edit>".  Entry of the edits is ended by a blank line or
 a Control-Z.  The EDITSET symbol can be defined by doing:

	EDITSET :== @FERMI$EXE:EDITSET

 EDITSET can also be called with a pre-stored list of files to edit.
 The command format in this case is:

	EDITSET  @file_list

 where file_list is the specification of the file whose contents are a
 series of file specifications, one per line.

1 HOME
 Command procedure to make "SET DEFAULT" commands a bit shorter to
 type by using the command:

	HOME   {dire}

 where dire is the (optional) directory or subdirectory specification. 
 If none is given, the HOME command returns to the login directory
 using SYS$LOGIN:.  If a parameter is given, it will be enclosed in
 square brackets if it is not a logical name (if the parameter is a
 logical name then it will used in the SET DEFAULT command as is).
 Special forms of the command are:

	HOME   \		!Backup one directory level
	HOME  -]		!Same as "HOME \"

 The command "HOME  \.subdire" is the same as a "HOME" command (no
 parameter) followed by a "HOME .subdire" command (return to a 1st
 level subdirectory below the login UFD).

 The HOME command can be define as:

	HOME :== @FERMI$EXE:HOME

1 FINDUIC
 FINDUIC is a programme to locate all files owned by a particular
 UIC.  The programme asks for a Disk, UIC, and Output Device then
 opens [0,0]INDEXF.SYS on the user-specified Disk.  All files
 owned by the UIC are then entered into an alphabetically-ordered
 tree, together with the FILE ID and Filesize.  (The Filesize is
 obtained by opening the File by FILE ID.  If the File is locked,
 or otherwise protected against the caller, **** will be returned
 for the File Size) FINDUIC should be defined as a foreign
 command:

	$ FINDUIC :== $FERMI$EXE:FINDUIC

 and then is called by typing:

	$ FINDUIC disk:[uic]

2 Parameters
disk
  name of a disk device whose [0,0]INDEXF.SYS file is searched
  for the files.  Defaults to SYS$DISK:
[uic]
  gives the file owner UIC of the files to be selected.  Defaults
  to the caller's UIC.
2 Qualifiers
/OUTPUT:output
 Select output for file list.  Defaults to SYS$OUTPUT:

1 STOPBYNAM
 Stops process(es) given the name of the process:

	@SYS$MGR_UTIL:STOPBYNAM  process_name  [STOP]

 Note that all processes with the same name are stopped, so beware!
 By default the processes are "stopped" by FORCEXIT.  If the second
 parameter is "STOP" then the processes are deleted using STOP.

1 TIMCHANGE
 Submit batch job to implement time change between Standard and Daylight-
 savings time (either way, determined by month) at 2 AM on a specified day.

	@SYS$MGR_UTIL:TIMCHANGE  day

 The day is entered as the day of the month on which the time change is to
 take place.

1 TOUSER
 Change to another user account by changing the default directory
 and UIC currently in use.  The format of the command is:

	TOUSER  username

 This procedure makes use of the file SYS$MANAGER:USERLIST.DAT to
 lookup user accounts.  If the username is found in USERLIST.DAT, then
 the UIC and login directory are gotten from the file and used to set
 the UIC and default directory of your process.  If no username is
 given, then the MYUIC symbol is used to return to the login UIC and
 the default directory is restored to SYS$LOGIN:

