Using Mac OSX version 10.14.x

Want to run a Python script every 5 minutes.

Created a shell script, check.sh and marked it executable so that it runs the Python script as shown below.

/usr/bin/python resolve.py

Created a crontab entry using crontab -e command as shown below.

5 * * * * ./check.sh

It is listed successfully using the crontab -l command:

$ crontab -l
5 * * * * ./check.sh

The Python script is supposed to create a log file which is updated each time it executes.

So, I would expect the cron job to execute every 5 minutes and the log file to be created. But this does not happen.

I'm not sure if the cron job is not executing or some other issue.

Please note that when I run the Python script directly, it executes properly and the log file is created.

1 Answer 1


Your cron job is scheduled to execute every hour 5 minutes after the hour. If you want it to run every 5 minutes change it to:

*/5 * * * * ./check.sh
  • Thank you for the response. It works.
    – Neon Flash
    Aug 21, 2020 at 23:51

You must log in to answer this question.

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