Bug #62033 [NEW]: php-fpm exits with status 0 on some failures to start

From: Date: Mon, 14 May 2012 22:00:38 +0000
Subject: Bug #62033 [NEW]: php-fpm exits with status 0 on some failures to start
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-170438@lists.php.net to get a copy of this message
From:             
Operating system: Linux (Ubuntu 12.04)
PHP version:      5.4.3
Package:          FPM related
Bug Type:         Bug
Bug description:php-fpm exits with status 0 on some failures to start

Description:
------------
When the php-fpm command fails because the 'user' value of a pool specifies
a nonexistent user, php-fpm exits with 0 rather than a non-zero status.
This is incorrect and causes problems with init scripts, for example.

This happens with both php 5.3 and 5.4.

Test script:
---------------
Snippet of a pool configuration which will trigger the bug:

[example.com]
user = fakeuser
...

Expected result:
----------------
php-fpm should exit with a non-zero status in all cases where there is an
error which causes it to fail to start (including, but not limited to,
nonexistent users).

Actual result:
--------------
$ php-fpm
[14-May-2012 14:39:40] ERROR: [pool example.com] cannot get uid for user
'fakeuser'
[14-May-2012 14:39:40] ERROR: FPM initialization failed
$ echo $?
0

-- 
Edit bug report at https://bugs.php.net/bug.php?id=62033&edit=1
-- 
Try a snapshot (PHP 5.4):            https://bugs.php.net/fix.php?id=62033&r=trysnapshot54
Try a snapshot (PHP 5.3):            https://bugs.php.net/fix.php?id=62033&r=trysnapshot53
Try a snapshot (trunk):              https://bugs.php.net/fix.php?id=62033&r=trysnapshottrunk
Fixed in SVN:                        https://bugs.php.net/fix.php?id=62033&r=fixed
Fixed in SVN and need be documented: https://bugs.php.net/fix.php?id=62033&r=needdocs
Fixed in release:                    https://bugs.php.net/fix.php?id=62033&r=alreadyfixed
Need backtrace:                      https://bugs.php.net/fix.php?id=62033&r=needtrace
Need Reproduce Script:               https://bugs.php.net/fix.php?id=62033&r=needscript
Try newer version:                   https://bugs.php.net/fix.php?id=62033&r=oldversion
Not developer issue:                 https://bugs.php.net/fix.php?id=62033&r=support
Expected behavior:                   https://bugs.php.net/fix.php?id=62033&r=notwrong
Not enough info:                     https://bugs.php.net/fix.php?id=62033&r=notenoughinfo
Submitted twice:                     https://bugs.php.net/fix.php?id=62033&r=submittedtwice
register_globals:                    https://bugs.php.net/fix.php?id=62033&r=globals
PHP 4 support discontinued:          https://bugs.php.net/fix.php?id=62033&r=php4
Daylight Savings:                    https://bugs.php.net/fix.php?id=62033&r=dst
IIS Stability:                       https://bugs.php.net/fix.php?id=62033&r=isapi
Install GNU Sed:                     https://bugs.php.net/fix.php?id=62033&r=gnused
Floating point limitations:          https://bugs.php.net/fix.php?id=62033&r=float
No Zend Extensions:                  https://bugs.php.net/fix.php?id=62033&r=nozend
MySQL Configuration Error:           https://bugs.php.net/fix.php?id=62033&r=mysqlcfg



Thread (12 messages)

« previous php.bugs (#170438) next »