RE: [CentOS] cron clarification

2008-01-01 Thread Joseph L. Casale
>Traditional crontab entries do still work, if you really want to deal
>with that, but it's harder to automate install/uninstalls.
>
>--
>
>rgds
>Stephen


Thanks Stephen and Jim!
jlc
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] cron clarification

2008-01-01 Thread Stephen Harris
On Tue, Jan 01, 2008 at 04:08:17PM -0700, Joseph L. Casale wrote:
> What is the ramifications to simply placing scripts in the /etc/cron.hourly 
> directory as opposed to actually adding jobs via the crontab -e method?
> Is there any significance to using one method versus the other?

If you don't need to run something at a specific time then cron.hourly
is easier and simpler.  Just drop the script into the directory.

If you need something at a specific time then look into /etc/cron.d/
which is similar to traditional crontab format, but again is simply a matter
of dropping files into that directory.
eg
  % cat /etc/cron.d/sysstat
  # run system activity accounting tool every 10 minutes
  */10 * * * * root /usr/lib/sa/sa1 1 1
  # generate a daily summary of process accounting at 23:53
  53 23 * * * root /usr/lib/sa/sa2 -A

Traditional crontab entries do still work, if you really want to deal
with that, but it's harder to automate install/uninstalls.

-- 

rgds
Stephen
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos


Re: [CentOS] cron clarification

2008-01-01 Thread Jim Perrin
On Jan 1, 2008 6:08 PM, Joseph L. Casale <[EMAIL PROTECTED]> wrote:
> What is the ramifications to simply placing scripts in the /etc/cron.hourly 
> directory as opposed to actually adding jobs via the crontab -e method?
> Is there any significance to using one method versus the other?

Using /etc/cron.hourly is better for applications which use cron jobs.
When you install the application, it just has to drop a file in a
directory rather than parsing a particular user's crontab. It also
provides a central location to look for jobs, rather than parsing a
number of different user files to figure out your hourly tasks (for
system user tasks, not actual people tasks).


-- 
During times of universal deceit, telling the truth becomes a revolutionary act.
George Orwell
___
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos