0

I have cron job that run every 5 minutes in my red hat machine.

2,17,32,47 * * * * root /usr/sbin/logrotate -s /var/opt/swms/log/logrotate.status /opt/swms/etc/logrotate.d/syslog

After running for nearly 100 minutes, its stopped working.

May  7 16:14:00 localhost crond[14979]: (CRON) STARTUP (V5.0)
May  7 16:17:01 localhost crond[15358]: (root) CMD (/usr/sbin/logrotate -s /var/opt/swms/log/logrotate.status /opt/swms/etc/logrotate.d/syslog)
May  7 16:32:01 localhost crond[17282]: (root) CMD (/usr/sbin/logrotate -s /var/opt/swms/log/logrotate.status /opt/swms/etc/logrotate.d/syslog)
May  7 16:47:01 localhost crond[19121]: (root) CMD (/usr/sbin/logrotate -s /var/opt/swms/log/logrotate.status /opt/swms/etc/logrotate.d/syslog)
May  7 17:01:01 localhost crond[20874]: (root) CMD (run-parts /etc/cron.hourly)
May  7 17:02:01 localhost crond[20996]: (root) CMD (/usr/sbin/logrotate -s /var/opt/swms/log/logrotate.status /opt/swms/etc/logrotate.d/syslog)
May  7 17:17:01 localhost crond[22853]: (root) CMD (/usr/sbin/logrotate -s /var/opt/swms/log/logrotate.status /opt/swms/etc/logrotate.d/syslog)
May  7 17:32:01 localhost crond[24691]: (root) CMD (/usr/sbin/logrotate -s /var/opt/swms/log/logrotate.status /opt/swms/etc/logrotate.d/syslog)
May  7 17:47:01 localhost crond[26538]: (root) CMD (/usr/sbin/logrotate -s /var/opt/swms/log/logrotate.status /opt/swms/etc/logrotate.d/syslog)
[root@localhost log]# date
Thu May  7 18:29:15 UTC 2015

I checked and Crond process is running. I have restarted syslog and crond services. Again facing the same issue after 1 hour.

Any help would be appreciated.

0

It may be that there is an error somewhere in your /etc/crontab file (or another crontab file, if you use others) which is preventing it from being parsed. You can check it with chkcrontab.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.