The syntax you use to create the backup program or batch file must adhere to the criteria described in the following list. The list is detailed and includes programming details. Do not attempt to write your own backup command unless you can follow these recommendations.
The backup program name must begin with either the prefix save or nsr and cannot exceed 64 characters.
The backup program must reside in the same directory as the Backup save command.
The Backup save command must be used in the backup program to ensure that the data is properly backed up.
All commands within the program file must be successfully executed; otherwise, Backup cannot complete the remaining instructions.
When you invoke the Backup save command, invoke the command with the following arguments: save "$@". Doing so enables the save command in your batch file to accept the arguments usually passed to it by the Backup savefs program during a routine backup operation.
The program should contain commands in the following order:
Run a pre-processing command before a client backup (optional).
Back up the data using the Backup save command (mandatory).
Run a post-processing command after a client backup (optional).
Follow these steps to create a pre- or post-backup command:
Use a text editor to create a program file in the directory where the Backup save command resides.
Enter the name of the backup program in the Backup Command attribute of the Clients resource.
Try backing up the client to ensure that the backup command you created works.
The following script is an example of a custom backup command that does pre- and post-processing. This script locks a ClearCase VOB (version object base), does the backup, then unlocks the VOB.