Mailinglist Archive: opensuse (3354 mails)

< Previous Next >
[opensuse] logrotate and crontab
  • From: Rejaine Monteiro <rejaine@xxxxxxxxxxxxxxxx>
  • Date: Thu, 29 Mar 2007 11:08:30 -0300
  • Message-id: <460BC85E.8080400@xxxxxxxxxxxxxxxx>
Hi,

I've been having a look on how crontab is setup on default Suse 9.2/10.0/10.1 servers,
since i wanted to find out when logs are being rotated.

as far as i can see, the default crontab entries (in /etc/cron.daily,
etc/cron.hourly etc.) are being scheduled via the /etc/crontab master file:

-*/15 * * * * root test -x /usr/lib/cron/run-crons && /usr/lib/cron/run-crons >/dev/null 2>&1
59 *  * * *     root  rm -f /var/spool/cron/lastrun/cron.hourly
14 4  * * *     root  rm -f /var/spool/cron/lastrun/cron.daily
29 4  * * 6     root  rm -f /var/spool/cron/lastrun/cron.weekly
44 4  1 * *     root  rm -f /var/spool/cron/lastrun/cron.monthly

but at what time does for example /etc/cron.daily/* get run ?

i assume it is the run-crons script that is responsible for this, but i can't see when
exactly all the different cron entries (daily for example) are being run.

it's important for me because i want to schedule sarg (squid statistics generator) at 2 pm and i want to be sure that i always run logrotate (to rotate squid logs) exactly might.

on redhat, the /etc/crontab is a lot clearer about this:

this is /etc/crontab on redhat:

# run-parts
01 * * * * root run-parts /etc/cron.hourly
59 23 * * * root run-parts /etc/cron.daily
22 4 * * 0 root run-parts /etc/cron.weekly
42 4 1 * * root run-parts /etc/cron.monthly

How can do that in Suse (run-parts don't work on suse?!)

Thanks,


--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx

< Previous Next >