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 31, “Managing Free Space with Thresholds.”
Creating 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:
Start isql and dump the transaction log to a holding area (for example, a temporary file).
Rename the dump file to a name that contains the dump date, time, and database name.
Make a note about the new backup in a history file.
Record any errors that occurred during the dump in a separate error file.
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: