search
HomeBackend DevelopmentPHP ProblemHow to modify php.ini and then restart

How to restart php-fpm after modifying php.ini: 1. Open "php-fpm.pid" and get the id; 2. Execute the command "kill -USR2 42890"; 3. Restart php-fpm. Can.

How to modify php.ini and then restart

The operating environment of this article: linux5.9.8 system, PHP5 version, DELL G3 computer

How to modify php.ini and then restart?

Restart php-fpm after modifying php.ini

It is recommended to open /usr/local/php/var/run/php-fpm.pid to get the id 42890

Direct kill -USR2 42890

best

php-fpm Close:

kill -INT 'cat /usr/local/php/var/run/php-fpm.pid'

php-fpm Restart:

kill -USR2 'cat /usr/local/php/var/run/php-fpm.pid'

Move file | Rename |

mv file name new path file name

Test whether the configuration is correct

nginx -t

nginx Restart

nginx -s reload

After installing the extension, Modify php.ini Add extension=/path/shmop.so

Restart php infinitely, nginx just doesn’t work

After checking phpinfo, I found that the value of Loaded Configuration File is none

It turns out that when php-fpm was started, php.ini was not specified, so it never took effect...

 /usr/local/php5/sbin/php-fpm -y /usr/local/php5/etc/php-fpm.conf -c /usr/local/php5/etc/php.ini

Recommended learning: "PHP Video Tutorial"

The above is the detailed content of How to modify php.ini and then restart. For more information, please follow other related articles on the PHP Chinese website!

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

MantisBT

MantisBT

Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

VSCode Windows 64-bit Download

VSCode Windows 64-bit Download

A free and powerful IDE editor launched by Microsoft

EditPlus Chinese cracked version

EditPlus Chinese cracked version

Small size, syntax highlighting, does not support code prompt function

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)