Do I need to restart Apache after changing the php.ini file?

前端 未结 4 777

If I make a change to a setting in the php.ini file - do I need to restart Apache in order for it to take effect?

4条回答
  •  执念已碎
    2020-11-29 06:12

    Depends, actually. Depends on how you use php inside that webserver:

    • using php a module: you have to restart the server process
    • using php as cgi backend: you do not have to restart the server process
    • using php fastcgi: not sure, actually... (restarting is on the safe side, though)
    • using PHP-FPM: you have to restart the fpm server process to prevent inconsistencies

提交回复
热议问题