Schedule jobs using 'at' command
at command is used to schedule jobs. It takes a series of commands as input and execute it at a particular time in the future. It differs from cron which is used for recurring executions (every hour, every day etc).
at offers the following keywords to be used for scheduling, now, noon, midnight, today and tomorrow. It also accepts the + operator. You can use hours, days, weeks, months and years keywords along with the + operator. For eg,
at 13
at 2.15pm
at midnight
at now + 1 day
at 3:30 January 26, 1986
To schedule job,
$ at 21:29 /export/rmanbkp.sh
$ at 13:15
at> /data_back/expprod.sh
ctrl-d
$
To view the scheduled jobs,
$ at -l
oracle.1266893940.a Mon Feb 22 21:29:00 GMT 2010
oracle.1269888300.a Mon Mar 29 13:15:00 GMT 2010
To remove a job
$ at -r oracle.1269888300.a
Note: There is no way you can find out the name of the program scheduled to run. Only job number is dislayed.
Thanks
Monday, March 29, 2010
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment