/////////////////////
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
# /the/tech/blog
Solutions for FreeBSD web and application servers using PHP, mySQL, Apache and more.
Posted By Adam
Monday, August 9th 2010

Adam StrohlSOLVED: Apache HTTPd Crashes or Goes Offline Exactly At Midnight

After updating Apache httpd on a server running FreeBSD, it went offline at exactly midnight the following night, producing a log entry like this in httpd-errors:

[Tue Aug 10 00:00:01 2010] [notice] SIGHUP received. Attempting to restart
[Tue Aug 10 00:00:01 2010] [notice] seg fault or similar nasty error detected in the parent process

The server would start right back up using an "apachectl start" command and everything seemed to work fine unless httpd was told to restart or restart gracefully ("apachectl graceful") and then it will crash.

In this case we had newsyslog(8) under FreeBSD rotating Apache httpd's log files at midnight. After it moves the files it then tells the server to restart so it established new file handles. This restart command was triggering the seg fault and ensuing crash.

After much testing, I deduced that it was a conflict between httpd itself and the PHP module "mhash.so". In this situation I was able to simply uninstall and disable it from the extensions.ini file as it was actually not needed.

loading icon

Fetching vote status, one moment ...

Add a Comment:

* Name:
* Email address:
Verification purposes only. Your email address will not be shown publicly, transfered, or sold. We don't spam and take data privacy seriously.
* Comment:
icon

Related Experience

Take a look at these related items:

Apache Server Support
FreeBSD® Admin. & Security

icon

Disclaimer

Any problems and their solutions discussed here are designed to be examples and may not exactly match your situation.

No warranty is provided or implied with these articles, if it's critical contact us: we support and guarantee all of our work.