Technical data

Using BACKUP
11.15 Backing Up User Disks
11.15.7.2 Using a Command Procedure for Nightly Incremental Backups
You can use a similar command procedure to perform nightly incremental backups
of your disks. It might be more convenient to perform nightly incremental
backups and weekly image backups if either of the following conditions applies:
Interactive users are on your system at all times, and system performance is
noticeably affected by backups.
A full backup does not fit on a single magnetic tape, but an incremental
backup does. In this case, an image backup requires the presence of an
operator (to change the tape), whereas an incremental backup can be run as a
batch job.
Suppose that you want to do nightly incremental backups at 11:00
P.M., except
on Friday night, when you want to do an image backup. The following command
procedure executes an incremental backup on three disks and automatically
resubmits itself to run again the following night, except for Friday night.
How to Perform This Task
To use the procedure, follow these steps:
1. From the SYS$MANAGER directory, create the command procedure as shown
and call it INCREMENTAL_BACKUP.COM.
$!
$! Resubmit this procedure --
$ SUBMIT/AFTER="TOMORROW+23:0" SYS$MANAGER:INCREMENTAL_BACKUP
$!
$ TODAY = f$cvtime("today",,"weekday")
$ IF TODAY .EQS. "Friday" THEN GOTO DONE
$!
$ ON ERROR THEN GOTO FAILURE
$ SET PROC/PRIV=(OPER,BYPASS)
$!
$ REPLY/ALL -
"Incremental Backup About to Begin. Open Files Will Not Be Saved"
$!
$ BACKUP/RECORD/SINCE=BACKUP DRA0:[000000...] -
MIA0:INCREMENT1.SAV /LABEL=INC1
$ BACKUP/RECORD/SINCE=BACKUP DRA1:[000000...] -
MIA1:INCREMENT2.SAV /LABEL=INC2
$ BACKUP/RECORD/SINCE=BACKUP DRA2:[000000...] -
MIA2:INCREMENT3.SAV /LABEL=INC3
$ DISMOUNT MIA0:
$ DISMOUNT MIA1:
$ DISMOUNT MIA2:
$ EXIT
$!
$FAILURE:
$ WRITE SYS$OUTPUT "---> Backup failed"
$ WRITE SYS$OUTPUT ""
$ DISMOUNT MIA0:
$ DISMOUNT MIA1:
$ DISMOUNT MIA2:
$ EXIT
2. Edit the procedure to reflect:
The names of the disks that you want to back up
The name of the tape drive that you will use
The volume label of the tape
The name that you want to assign to the save set
Using BACKUP 1141