I'm in Ubuntu linux.
I just added this cron-job to run every minutes
MAILTO="[email protected]"
* * * * * cd /home/forge/bheng/public/code/scraper/; /usr/bin/python3 main.py
If I run this command
cd /home/forge/bheng/public/code/scraper/; /usr/bin/python3 main.py
It works fine.
I never see it run or get an email.
I ran a mail
command
I got
└── mail
"/var/mail/root": 3 messages 3 new
>N 1 Cron Daemon Sun Oct 15 06:34 21/930 Cron <root@bheng> test -x /usr/sbin/anacron || ( cd / && run
N 2 long@bheng Sun Oct 15 14:19 15/649 *** SECURITY information for bheng ***
N 3 long@bheng Sun Oct 15 14:19 15/649 *** SECURITY information for bheng ***
?
It seems to have issues, how do I fix it ?
Did I forgot something or missing something?
bash
script and tellcron
to run the script. Easier control, debugging,bash
command interpreter rather thancron
's./usr/bin/python3 /home/forge/bheng/public/code/scraper/main.py
instead and see if it workscd
; use/usr/bin/python3 /home/forge/bheng/public/code/scraper/main.py
instead.* * * * * cd /home/forge/bheng/public/code/scraper/; /usr/bin/python3 main.py >/tmp/out 2>/tmp/errs
, do you see anything in either of those files in /tmp after waiting for a minute?