title: run killall command in php shell_exec function
body: <p>I have a working shell script using killall to kill all instances of a program like below:</p>
  
  <p>killall abc</p>
  
  <p>Now, I write a php webpage to execute this script using shell_exec function:</p>
  
  <p>shell_exec('sh ./myscript.sh');</p>
  
  <p>Problem is that my php code works correct on commandline with "php myscript.php", but not works in browsers!. However, I know that the user in commandline is "root" and in php is "apache" (I get this with 'whoami').
  The linux distribution is Centos 6 which uses SElinux. I changed the status of selinux to permissive.</p>
  
  <h2><strong>Things I've checked:</strong></h2>
  
  <ul>
  <li>PHP safe_mode is off</li>
  <li>shell_exec() is not present in disable_functions in php.ini</li>
  </ul>
  
  <p>Is there a way to run scripts with kill command using php?</p>
  
  <p>Thank you for your help.</p>