-
What's the difference between running a job as a cron job and a batch job?
-
cron job is programmed, batch job is doing loads of tasks in a go.
they are both related because normally you program batch jobs with cron and to execute them in an hour when the activity is low (early morning like 2 am to 4 am for example depending your company)
cron jobs can be batch jobs, backups, monitoring etc
batch jobs can be mass data loading, mass updating etc
-
"cron" is usually mentioned as a Unix utility- which basically calls a script or a "one-liner" at any given time or interval listed in your crontab. I'm not sure if the actual cron program is available for NT- I just use Unix.
So ... if you have a unix box just try the man page:
%man cron
You may try:
%crontab -l
Which will list the current cronjobs for the current user.
%crontab -e
will edit the crontab. Make sure you do a:
export EDITOR=vi
so that cron knows which editor you use.
-
Another difference between a 'crontab'-job and an 'at'-job.
When you issue a job using at, the unix-environment is automatically put in the job. eg. when you have set your oracle environment, and you start a job using at, automaticly you have the right oracle settings.
When you issue a job using crontab, you have to set the environment in the script. That's why I always begin a crontab job with
. /etc/profile
. $HOME/.profile
Regards
Gert
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|