We are moving to a new server and on this server we find that the PHP functions exec,passthru,shell_exec, and system are disabled. We know that from running phpinfo and also when we run a PHP program that uses exec, it warns us that it is disabled. So I thought I would just change this in the php.ini file. Phpinfo tells me the load configuration file is /opt/cpanel/ea-php71/root/etc/php.ini. In there I find:
Also when I run php –ini in the terminal I find
I’ve looked through all the files in /opt/cpanel/ea-php71/root/etc/php.d and don’t find anything there either. Finally, even though it shouldn’t be there, I checked httpd.conf also.
How can this be? Our server does have puppet service installed and running. Could this be doing this and if so how?
Update:
Additionally I changed the php.ini file so
and there was no change in what I see in phpinfo, i.e.,
disable_functions =
Also when I run php –ini in the terminal I find
disable_functions => no value => no value
I’ve looked through all the files in /opt/cpanel/ea-php71/root/etc/php.d and don’t find anything there either. Finally, even though it shouldn’t be there, I checked httpd.conf also.
How can this be? Our server does have puppet service installed and running. Could this be doing this and if so how?
Update:
Additionally I changed the php.ini file so
disable_functions = "popen"
and there was no change in what I see in phpinfo, i.e.,
exec,passthru,shell_exec,system Update: I can the run PHP script that uses exec from the command line and it works, but not when it is run from a browser. So it appears apache is disabling the functions somehow. I didn't thing that could be done, but I had looked in the httpd.conf anyway and didn't find anything. |
Last edited: