title: php-fpm does not work exec, system, shell_exec, only CLI
body: <p><code>php-fpm</code>, <code>nginx</code> exec when in use <code>.phpfiles()</code> <code>shell_exec()</code> <code>system()</code> works fine from the command line.</p>
  
  <p>Example when works well:</p>
  
  <pre><code>#php myphp.php
  </code></pre>
  
  <p><code>myphp.php</code> contains:</p>
  
  <pre><code>&lt;?php
  exec('ping -c 3 google.com', $output);
  print_r($output);
  ?&gt;
  </code></pre>
  
  <p>But if I put on my browser <code>http://localhost/myphp.php</code>, it does not work anymore.</p>
  
  <p>Any ideas?
  I edit</p>
  
  <p>I made a file with the following contents:</p>
  
  <pre><code>#cat info.php
  
  &lt;?php
  if(function_exists('exec')) {
      echo "exec is enabled";
  }
      phpinfo();
  ?&gt;
  </code></pre>
  
  <p>In my browser, print </p>
  
  <blockquote>
    <p>exec is enabled, y php info..</p>
  </blockquote>
  
  <p>I made a file with the following contents:</p>
  
  <pre><code>#cat info.php
  
  &lt;?php 
  // Check for safe mode
  if( ini_get('safe_mode') ){
      // Do it the safe mode way
  echo "Do it the safe mode way";
  }else{
      // Do it the regular way
  echo "Do it the regular way";
  }
  
  ?&gt;
  </code></pre>
  
  <p>In my browser, print</p>
  
  <blockquote>
    <p>Do it the regular way</p>
  </blockquote>
  
  <p>Did not I like to know if I'm in a jail?</p>
  
  <p>In my php ini </p>
  
  <pre><code>#cat /etc/php-5.5.ini
  </code></pre>
  
  <p>safe_mode not shown, or ON or OFF.
  simply does not exist</p>