Apache 2.2 sometimes restart failed

kalaj

Verified User
Joined
Jun 13, 2007
Messages
20
Sometimes my server's service down, I found that the system has only one httpd process, Apache was half-dead.

Sometimes I restart Apache manually, I got these error:

root@cph:~# /etc/init.d/httpd restart
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Stopping httpd:
Remaining processes: 20328
Starting httpd:

(98)Address already in use: make_sock: could not bind to address 218.240.14.21:80
no listening sockets available, shutting down
Unable to open logs

And I find "[Fri Jan 18 09:05:04 2008] [notice] caught SIGTERM, shutting down" in error log, no other error messages.

It seems /etc/init.d/httpd has a problem, it can't kill all httpd processes when restart Apache sometimes.

Any help, Thanks a lot :(
 
Sometimes my server's service down, I found that the system has only one httpd process, Apache was half-dead.

Sometimes I restart Apache manually, I got these error:



And I find "[Fri Jan 18 09:05:04 2008] [notice] caught SIGTERM, shutting down" in error log, no other error messages.
It is likely that a module or library is corrupted causing this problem. I suggest you re-compile Apache. See if that helps!
 
Thanks, I'' have a try.

BTW, I notice that my previous httpd init script there was no "Remaining processes: " message when restarting.
 
Recompiled Apache, the problem still occur :mad:
Stop Apache and killall remaining processes and start it again
killall httpd
killall -9 httpd

Then restart:
/sbin/service httpd restart

Make sure your partitions did not exceed their allocated quota by running this command:
df -Th

In addition, check out these threads: http://www.directadmin.com/forum/showthread.php?t=2326&page=2
http://www.directadmin.com/forum/showthread.php?t=17004&page=9
http://www.directadmin.com/forum/showthread.php?t=16779

If none of the above helped, I suggest you seek professional help.
 
Back
Top