HP (Hewlett-Packard) B6960-90078 Computer Drive User Manual


 
Backup
Pre- and Post-Exec Commands
Chapter 5258
How to Specify the
Filename or
Pathname?
For information on how to specify the commands, refer to the online Help
index keyword “pre- and post-exec commands for backup specifications”.
Environment
Variables
The following environment variables are exported, and can be used in
pre- and post-exec scripts for a backup specification session on any
host:
DATALIST The name of the backup specification.
MODE Backup operation type, such as full, incremental,
incremental1, and so on.
OWNER Owner of the session.
The content of this variable is in the same format as in
the database (case-sensitive):
<user>.<group>@<hostname> for UNIX and
<DOMAIN>\<user>@<hostname> for Windows NT.
PREVIEW Set to 1, if the preview is running. Set to 0, if a backup
is running. Use this variable to modify your commands
so that they are executed only during a backup and not
during a preview. By default, pre- and post-exec
commands are not executed for preview. You can
enable this with global option ExecScriptOnPreview.
RESTARTED Set to 1 if this is a restarted Backup session, otherwise
set to 0. The post-exec can use this variable to
prevent an additional restart if SMEXIT equals 0.
SESSIONID Is used to identify a finished session and is recorded in
the database. You cannot use this to preview a session
(use SESSIONKEY).
SESSIONKEY Is used to identify a running session. You may, for
example, abort a backup session before it is started if
something is wrong.
SMEXIT The exit code of the Session Manager is the same as the
exit code of the omnib command. You can only use this
variable with the post-exec command. Agents can
refer to Disk Agents, Media Agents, Application
Agents, and Symmetrix Agents. Refer to Table 5-3 on
page 253 for details on SMEXIT values.