The UNIX cron feature is a bulletproof, flexible, easy-to-use, and reliable mechanism to schedule periodic tasks such as backups. Because many of NNM’s files are owned by root, the backup script should be executed by root’s crontab entries. The cron feature is so easy to use there are only two variations that need be covered:
crontab -l lists the crontab entries
crontab file creates the crontab entries from file
An example file might contain the following lines:
# run five minutes after midnight, every day 0 * * * $HOME/bin/nnm_backup_job >> $HOME/tmp/out 2>&1
The first five fields represent time (see Table 11-1) and the rest of the line is the command to be executed when the time matches. This command should invoke ovbackup.ovpl (NNM 6.x).
Field | Allowed Values |
---|---|
minute | 0-59 |
hour | 0-23 |
day of the month | 0-31 |
month | 0-12 (or names like jan, feb, mar, ..., dec) |
day of the week | 0-7 ( 0 or 7 is Sunday, or names like sun, mon, ...sat) |
3.133.158.36