Rotate cron.daily on SUSE at a certain time.

At the moment my logs are rotating via logrotate at various different time.
To rotate at a certain time edit variable DAILY_TIME in /etc/sysconfig/cron

For example: DAILY_TIME="00:01"

Otherwise the way to do it involves making the creation time of /var/spool/cron/lastrun/cron.daily the hour and minute you want. This can be done by an at job since you don’t want to hang around to do that. To understand why creation time and not modification time, read /usr/lib/cron/run-crons, in particular the find statement.

Leave a Reply

Your email address will not be published. Required fields are marked *