run script with parameter in cron [duplicate]
Solution 1:
Redirect the error to file will help you debug easier:
*/10 * * * * root python /home/project/manage.py slope_update >> /tmp/foo.log 2>&1
Solution 2:
Try putting the full path to python in your crontab e.g.
*/10 * * * * root /usr/bin/python /home/project/manage.py slope_update
Edit:
The problem will be that the PATH in cron does not include the directory where python is installed (/usr/bin) so you need to supply the full path to python.
Edit Edit:
You are running this from your /etc/crontab ? If not then the root parameter is not required and may be causing problems.
Check email for mail from cron as it sends output from a job to you.
Check where your python lives, which python
and adjust the path in the crontab accordingly.