Automate backup procedures

Creating an automated backup procedure takes the guesswork out of performing backups and makes the procedure easier and quicker to perform. Automating backups can be as simple as using an operating system script or a utility (for example, the UNIX cron utility) to perform the necessary backup commands. Or you can automate the procedure further using thresholds, which are discussed in Chapter 29, “Managing Free Space with Thresholds.”

StepsCreating an automated backup procedure

Although the commands required to create an automated script vary, depending on the operating system you use, all scripts should accomplish the same basic steps:

  1. Start isql and dump the transaction log to a holding area (for example, a temporary file).

  2. Rename the dump file to a name that contains the dump date, time, and database name.

  3. Make a note about the new backup in a history file.

  4. Record any errors that occurred during the dump in a separate error file.

  5. Automatically send mail to the System Administrator for any error conditions.

Although the commands required to create an automated script vary, depending on the operating system you use, all scripts should accomplish the same basic steps: