R
R
Roman Radic2020-11-24 14:59:18
linux
Roman Radic, 2020-11-24 14:59:18

Why changes in php.ini don't change the value in phpinfo?

There is a cloud server in Scaleway with Ubuntu 20.04, nginx and php-fpm 7.2. I installed wordpress and a blog theme on it. In the theme settings, it gives a warning about the small value of max_input_vars.

5fbcf29ab53db125018268.png

The phpinfo function shows that the php.ini file is located in /etc/php/7.2/fpm/php.ini

5fbcf34a76072871068530.png

Edit the php.in file

5fbcf3d38b61a324108045.png

and change the value of max_input_vars = 5000

5fbcf416563e0205623015.png

save the file and restart the web server systemctl restart nginx (I also tried restarting the server) and nothing changes. Phpinfo shows that the max_input_vars size is 1000

5fbcf5239b0ac000298240.png

and also a warning in the theme settings. What am I doing wrong?

Answer the question

In order to leave comments, you need to log in

5 answer(s)
F
FanatPHP, 2020-11-24
@user28

because you are restarting the web server and you need to - PHP

G
galaxy, 2020-11-24
@galaxy

Separate parameters from php.ini can still be set in the FPM pool config (in Ubuntu in the /etc/php/7.4/fpm folder plus the conf.d/ directory in it), in the Apache and .htaccess configs (not relevant for you), and in WordPress itself (wp-config.php - in the form of ini_set). Search with grep.

S
Sanes, 2020-11-24
@Sanes

php-fpm is not restarted or the rule is specified in the php-fpm pool.

N
Nird, 2020-11-24
@Nird_o

Assumption. In addition to the global php configuration file, there are also configuration files for each virtual host, which is specified in the settings of this virt. host. And as far as I understand, it is a priority.

I
Ilya S, 2020-11-24
@Stalinko

sudo service php7.2-fpm restart

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question