Crontab strats 2 processes, calling 1 script
My crontab had the command:
Quote:
Code:
ps aux | grep SCRIPT Quote:
I made a change to my script and in order to get the new behaviour, I had to kill the currently running scripts and I used Code:
kill 13898 13900 Code:
/home/MY_SCRIPT.py /home/arguments 2> /dev/null
Everything looks good till here, but this time the killall MY_SCRIPT in the cronjob didnt work, it said could not find pid. And the script kept on running until I had to manually kill it. Need to find out the reason for this behaviour:
|
The cron daemon needs to invoke a shell to process the "2>/dev/null" redirection. The only way I can think of to get rid of that shell process is to change MY_SCRIPT.py to a shell script that explicitly exec-s the python interpreter:
Code:
#!/bin/sh |
All times are GMT -5. The time now is 06:17 PM. |