I'm having a very difficult case with latest php5-fpm (from debphp) and nginx 1.4.3 on Ubtuntu 12.04LTS.

In short, I cannot start php5-fp at all, I keep getting this error in syslog:

kernel: [1213013.564441] init: php5-fpm main process (7357) terminated with status 78
kernel: [1213013.564496] init: php5-fpm main process ended, respawning
..... (repeated several times)
kernel: [1213014.143911] init: php5-fpm respawning too fast, stopped

My /var/log/php5-fpm.log is not populated at all. There is no php5-fpm.sock and php5-fpm.pid in /run (or /var/run).

My /etc/php5/fpm/php-fpm.conf is below: (this file doesn't seem to be loaded now as I tried to put some bogus info into it but didn't cause any change)

; FPM Configuration ;


; Global Options ;

; Pid file
; Note: the default prefix is /var
; Default Value: none
pid = /run/php5-fpm.pid
catch_workers_output = yes

; Log level
; Possible Values: alert, error, warning, notice, debug
; Default Value: notice
log_level = debug

; To configure the pools it is recommended to have one .conf file per
; pool in the following directory:

Permission checking:

ls -l /etc/php5/fpm/php-fpm.conf

-rwxrwxrwx 1 root root 4641 Nov  6 01:37 /etc/php5/fpm/php-fpm.conf

My include=/var/www/vhosts/mysite.com/w/w/w/www/config/fpm-pool.conf (this file does not seem to be loaded anymore)

    listen                 = /run/php5-fpm.sock
#    listen                =
    listen.backlog         = -1
    listen.allowed_clients =
    listen.owner           = www.mysite.com
    listen.group           = mysite.com
    listen.mode            = 0666

    user  = www.mysite.com
    group = mysite.com

    pm                   = dynamic
    pm.max_requests      = 0
    pm.max_children      = 15
    pm.start_servers     = 2
    pm.min_spare_servers = 1
    pm.max_spare_servers = 3

    pm.status_path       = /php_pool_wwww.mysite.com_status
    ping.path            = /www.mysite.com_ping
    ping.response        = www.mysite.com_pong

    request_terminate_timeout = 30
    request_slowlog_timeout   = 20
    slowlog                   = /var/www/vhosts/mysite.com/w/w/w/www/logs/php-slow.log

    rlimit_files = 131072
    rlimit_core = unlimited

     chroot = /var/www/vhosts/mysite.com/w/w/w/www/
    ; Chdir to this directory at the start. This value must be an absolute path.
    ; Default Value: current directory or / when chroot
    ; chdir = /htdocs

    catch_workers_output = yes

    env[TMP]      = /tmp
    env[TMPDIR]   = /tmp
    env[TEMP]     = /tmp

    security.limit_extension = .php
    ;   php_value/php_flag             - you can set classic ini defines which can
    ;                                    be overwritten from PHP call 'ini_set'.
    ;   php_admin_value/php_admin_flag - these directives won't be overwritten by
    ;                                     PHP call 'ini_set'
    php_flag[display_errors]            = on
    php_admin_value[error_log]          = /logs/php_err.log
    php_admin_flag[log_errors]          = on
    php_admin_value[memory_limit]       = 100M
    php_value[max_execution_time]       = 300

Permission checking:

ls -l /var/www/vhosts/mysite.com/w/w/w/www/config/fpm-pool.conf

-rwxr-xr-x 1 www.mysite.com mysite.com 1830 Nov  6 01:05 var/www/vhosts/mysite.com/w/w/w/www/config/fpm-pool.conf

User/Group Permission checking:

groups www.mysite.com

www.mysite.com : www.mysite.com www-data mysite.com

I don't think this has anything to do with nginx because php5-fpm itself cannot start at all right now anyhow, but for the sake of having all info: nginx is also set to use same user/group

  • Try to set loglevel to debug in /etc/php5/fpm/php-fpm.conf. That should give you some clues in the error log (path in error_log variable in the same config file). This helped me. The problem on my setup, was that there were conflicting values in the pm.* variables in /etc/php5/fpm/pool.d/www.conf. The only symptom was the exact same as you describe in your question.
    – Frank
    Aug 28, 2014 at 11:44
  • I got this when I made a typo in my listen directive path. Double-check that the directory you give for your listen directive exists if listening on a unix socket.
    – user301752
    Jul 28, 2015 at 7:05
  • For future readers, the permissions on the config files have nothing to do with this; they only need to be readable to the user a service runs under. You definitely don't need them executable nor world-writeable.
    – Walf
    Jun 5, 2017 at 23:33

3 Answers 3


The process that upstart was watching died, but the pool workers are still running. To fix it, run:

sudo killall php-fpm
sudo start php5-fpm

The php5-fpm job will repeatedly exit with status 78 until all of the old worker threads are dead. Note that the server is typically functional in this state, even though upstart isn't managing the service. When it eventually dies, though, it won't automatically respawn, so it should be fixed ASAP. A simple reboot will also fix the problem, but will result in downtime.

  • 1
    killall gave me a php-fpm: no process found response. I executed ps aux | grep php and then manually killed all php processes. After that I could successfully restart php5-fpm service. Oct 12, 2015 at 19:23
  • Didn't work for me. There are no php-fpm processes running according to ps aux. Jun 1, 2017 at 17:14
  • @Jake Wilson Did you check to see if it's under a different name? Try grepping for php or fpm instead of php-fpm. Some distros put the version number in the middle.
    – Zenexer
    Jun 1, 2017 at 17:48
  • Ya for me it's php5.6-fpm. Still not seeing it. syslog is showing it crashing with an error 78 whenever I try to start it. Still trying to sort this out. Jun 2, 2017 at 3:29
  • 1
    I had to use killall php5-fpm - see my full answer for more details.
    – SharpC
    May 11, 2021 at 13:46

I also got these errors in /var/log/syslog:

init: php5-fpm main process (7357) terminated with status 78
init: php5-fpm main process ended, respawning
init: php5-fpm respawning too fast, stopped


  • I tried using these tips but found no difference.

  • Adding php5-fpm as a service didn't work using:

      update-rc.d php-fpm defaults

    even if I only triggered it only at specific run levels. This can be removed again using:

      update-rc.d -f php-fpm remove
  • Without installing as a service, php5-fpm would still attempt to start (and fail)

  • Running service --status-all | grep php always showed php5-fpm as stopped, even after my fix below.


Using the kill tip from @Zenexer though I got the following script to work:

# start-php5-fpm-reboot.sh
# Add a delay, otherwise the script fires too soon
sleep 30

# Kill all php5 children
killall php5-fpm

# Start the php5-fpm service
/usr/bin/service php5-fpm start

Place it in e.g. /etc/php5/fpm, ensure root has exectuable permissions, then add it as a cron job by using sudo crontab -e and adding the following line:

@reboot /etc/php5/fpm/start-php5-fpm-reboot.sh

I recently encountered this same issue. It turns out that another process was already listening on the same port. To discover which process was running, I ran the following command:

sudo netstat -nltp

Turns out that hhvm was already listening on port 9000.

tcp6       0      0 :::9000                 :::*                    LISTEN      17765/hhvm      

As soon as I stopped the hhvm daemon, php5-fpm successfully started.

  • Now that I take a closer look at the fpm-pool.conf posted in the question, php5-fpm was not configured to listen on a port, but to use a sock. However, I'll keep this answer here in case anyone else encounters the same problem I ran into.
    – Jimmy Z
    Mar 12, 2015 at 15:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.