I can't kill process in php script on Ubuntu <p>i run shell in command line in 1 hours. I want use PHP script to stop it . I known its $pid is 2000 by use getmypid();</p> <p>I used PHP script as: <code>exec("kill 2000");exec("kill -KILL 2000"); exec("kill -9 2000"); posix_kill(2000,9);</code> but can't kill it.</p> <p>If in terminal, i simple use <code>~$ kill 2000</code> .But can't with php script . </p>