I have this problem and I can't figure out why... I have a php-fpm + nginx configuration.

I see in the php-fpm logs that every day at 0,6,12,18 hours the server kill all children and restart itself. It works, however there are like 30 seconds or so each time when nginx respons bad gateway.

Any idea what can cause this?

  • Have you tried to see if someone has installed some kind of cronjob to restart nginx on that schedule? Oct 18, 2013 at 13:45

1 Answer 1


This can happen due to log rotation. Rotation routine sends signal to demon for he could reopen it's log files. Some daemons just restart on this signal. Check /etc/newsyslog.conf (if you are running FreeBSD) or /etc/logrotate.conf and /etc/logrotate.d/* (Linux) for related tasks.

Also check /etc/cron.* and /etc/crontab. Do not forget to check root crontab and crontab of user running nginx/php-fpm if it is not root:

crontab -l -u root
crontab -l -u USER

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.