1

I recall creating a cron job that runs a shell script that deletes files that are 45+ days old. When I was editing crontab -e I set it to also output a log to a date stamped log file to ~/Logs.

I want to remove this job, and now I cannot find it. Nothing shows up under crontab -l and I also checked launchctl list (as I wasn't sure if I made it a launchd job) but couldn't find anything there.

I know that the script name is remove_old_clips.sh so I tried various ways to find and fgrep for the string 'remove_old_clips' inside every file on the computer to see if I could locate where the job was being performed.

Nothing is located in /usr/lib/cron/tabs/ either.

If I know the name of the script, and I know where it is being logged to, how can I find what is automatically running this task every night at 1:35am?

1
  • 1
    In addition to the per-user crontab files, there can also be a system crontab, probably at /etc/crontab. There might also be /etc/cron.* directories. Check to see if it's in any of those. Commented Aug 24, 2019 at 8:48

1 Answer 1

0

This must have been a bug. As soon as I opened crontab -e when I was initially trying to work on this, it stopped logging. Not sure how or why my initial crontab jobs were erased, but I simply recreated them and everything is fine now.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .