Cron jobs are either user specific or system wide. You can list user specific cron jobs for all users by running the following command as root:
for user in $(cut -f1 -d: /etc/passwd); do crontab -u $user -l; done
(source)
If it's not found, it's probably a system wide cron job and it's located in one of the following folders:
etc/crontab
etc/cron.d
etc/cron.daily
etc/cron.hourly
etc/cron.monthly
etc/cron.weekly
Try running: grep -rnw '/etc/' -e 'keyword'
This command lists you all the files inside /etc/
which contain the keyword you are looking for, so it might also list you unrelated files.
In my case, the LetsEncrypt certificate renewal job turned out to be in etc/crontab
, which I thought I had checked already with crontab -e
, but it turns out they are different: crontab -e
is for user specific cron jobs, while etc/crontab
is for system wide cronjobs. This is also the reason why this cron job didn't appear when I was listing all cron jobs for all users.