We are trying figure out how to get our Netbackup server to issue commands on a client to shutdown Oracle so we can do a cold backup, and then restart Oracle after it done.
Server is RedHat Linux and client is HPUX.
Looks like your best bet then is the bpstart_notify and bpend_notify scripts on the client.
You should be able to find information about these in the NBU Sys Admin Guide II.
Things to note about these scripts.
- They cannot produce any output on either stdout or stderr as these are interpreted within the NetBackup client environment and can cause backup failures.
- If the bpstart_notify exists with a non-zero value, the backup will be cancelled with a status of 73.
- The bpend_notify script is always run, no matter what the exit status of the backup was. (either good or bad)
- If you enable Multiple Data Streams within the policy, you will have one bpstart_notify and one bpend_notify for each child job on each client in this policy. You will have to add code within the scripts to prevent the database restarting while other jobs are still running.
- Stream 1 of a multiple data streams job may not necessarily be the first stream to start. (so the first stream should shut things down, which could be stream 2, or 3 or even 5)
- Both the start and exit scripts are provided with command line arguments and preset environment variables. You can refer to the Guide listed above for more information.