Skip to content
Advertisement

php.ini updates not reflected in phpinfo() output

I am trying to update memory_limit in php.ini, but I don’t see the value updated in phpinfo(). Here is the ini file path info from phpinfo():

JavaScript

Updated /etc/php.ini and then ran:

JavaScript

I tried updating other values in ini file to see if anything gets updated, but nothing does.

I am on an AWS EC2 linux instance with wordpress.

Advertisement

Answer

Many modern PHP installations run PHP-FPM by default, instead of as an Apache module mod_php. PHP-FPM is itself a separate service that needs to be restarted via your operating system’s preferred method. e.g.

JavaScript

You mentioned you already knew which php.ini to modify from the phpinfo() output. For future readers, the PHP-FPM service may use a different php.ini. Consult the output from phpinfo() when loaded via the web to find out which php.ini to modify.

User contributions licensed under: CC BY-SA
8 People found this is helpful
Advertisement