I have a PHP script on server that sends newsletter emails to my site users using a cron job. The users list is approximately 55,000 and takes nine hours.
Is there any way to stop it (urgently)?
|
I have a PHP script on server that sends newsletter emails to my site users using a cron job. The users list is approximately 55,000 and takes nine hours. Is there any way to stop it (urgently)? |
||||
|
http://unix.derkeiler.com/Newsgroups/comp.unix.admin/2006-09/msg00132.html You need to get the PID of your running cron job and then perform simple kill command. |
|||||||||
|
|
someone already wrote u the answer, try:
|
|||
|
|
|
I wouldn't suggest allowing the use of system(), exec(), passthru(), etc. Its a security issue. If you do have a control panel, there has to be a way to manage the cron jobs, and I believe with most of them you also have the ability to launch an SSH session. You could use this method to stop/start the running process. Last but not least, if you can't stop it yourself, contact your host. |
|||
|
|
|
Just comment out the specific cron job you want to not run. Switch to the user that controls the task, export your editor of choice into the environment, then use crontab -l:
If you are using cPanel. GO to Advance section of the Corn Job and click the Delete button. If the delete button is not there, switch cPanel skin to 'X' to view the Delete button. |
|||||
|
ps -ewill give you the list of process, andkill processid(processid is a number) – Ibu May 16 '11 at 4:54