If php.ini is incorrect, php-frm starts without warning with default values
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
php7.0 (Ubuntu) |
Triaged
|
Medium
|
Nish Aravamudan | ||
Xenial |
Triaged
|
Medium
|
Nish Aravamudan |
Bug Description
OS: Ubuntu 16.04 Xenial
PHP: php7.0-fpm 7.0.8-0ubuntu0.
If /etc/php/
To make php.ini incorrect, just add this line:
# Wrong comment (
Systemd servive unit for php7.0-fpm has config check:
ExecStartPre=
But is does not work:
root@xenial:~# /usr/sbin/
PHP: syntax error, unexpected '(' in /etc/php/
[14-Sep-2016 14:24:46] NOTICE: configuration file /etc/php/
root@xenial:~# /usr/lib/
0
So, if php.ini is incorrect, php-fpm silently starts with default values: post_max_size=8m, expose_php is enabled, disable_functions is empty and so on.
Hello and thank you for reporting this bug.
With 16.10, the helper script has been removed, so the problem is not exactly reproducible. With 16.04, it looks to be a simple typo with the grep ([ERROR] rather than ERROR) in the script. Modifying it in that way leads to a successful prevention of php-fpm starting on parse errors. I will work on fixing 16.10 (if possible) and then SRU'ing the fix for 16.04.
Thanks,
Nish