2

How can I see all cron records in CentOs7? Is there a folder with a file that contains all the cron records?

9

You can find cron jobs from the following locations:

  • /etc/crontab
  • /etc/cron.d/
  • /etc/cron.daily/
  • /etc/cron.hourly/
  • /etc/cron.monthly/
  • /etc/cron.weekly/
  • /var/spool/cron/

The last entry contains a crontab file for each user who is using crontab.

There is also a default log file for cron daemon, which will contain information about cron runs, /var/log/cron.

2

Since this is CentOS 7 running systemd, you might also check systemd timers:

systemctl list-unit-files --type=timer
1

Refer the following file to see the cron records :

/etc/crontab

Also look for files in :

cron.daily, cron.d, cron.hourly,cron.monthly, cron.weekly under /etc and /var/spool/cron/.

To see list of cron jobs under the current user:

crontab -l

To see the logs from /etd/init.d/crond refer /var/log/cron For more refer this.

Could you please tell what are the contents in /etc/crontab.php?

  • Thank you, I have the /etc/crontab.php file, but it wal last upadted in 2014(!!) Is there a nother possible location where I can find the cron records? – DavSev Feb 27 '17 at 7:04
  • The actual file could be /etc/crontab, so what does /etc/crontab.php contain? Also look for cron.daily, cron.d, cron.hourly,cron.monthly under /etc and execute crontab -l, if you want to check logs, refer /var/log/cron – ss_iwe Feb 27 '17 at 7:24
  • @saisasanka please edit your question to include additions to your answer. – countermode Feb 27 '17 at 8:03

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.