Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 4th September 2008, 19:38
Hans Hans is offline
Moderator
 
Join Date: Dec 2005
Location: Montfoort, The Netherlands
Posts: 2,263
Thanks: 216
Thanked 649 Times in 295 Posts
Default Apache error: Bad file descriptor: apr_socket_accept

Within my Apache2 error.log file, i see several error messages like:

[error] (9)Bad file descriptor: apr_socket_accept: (client socket)
[error] (9)Bad file descriptor: apr_socket_accept: (client socket)
[warn] long lost child came home! (pid 12345)
[notice] Graceful restart requested, doing restart
[error] (9)Bad file descriptor: apr_socket_accept: (client socket)
(9)Bad file descriptor: apr_socket_accept: (client socket)

The Bad file descriptor error message seems to appear everytime Apache restarts.
Does anyone what this error message means?

I had this problem in the past too and understand that it seams to be a bug in Apache2, but now i am not sure...

Debian Etch/Apache 2.2.3.

Can anyone tell me more about such an error end if possible how to ovoid it.

Thanks in advance!
__________________
Hans

MrHostman | Managed Hosting

Last edited by Hans; 4th September 2008 at 19:56.
Reply With Quote
Sponsored Links
  #2  
Old 5th September 2008, 13:34
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,748 Times in 2,579 Posts
Default

Have you tried to upgrade Debian's Apache package?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #3  
Old 5th September 2008, 14:50
Hans Hans is offline
Moderator
 
Join Date: Dec 2005
Location: Montfoort, The Netherlands
Posts: 2,263
Thanks: 216
Thanked 649 Times in 295 Posts
Default

Quote:
Originally Posted by falko View Post
Have you tried to upgrade Debian's Apache package?
(I know it is not the latest Apache2 version available) but the latest Apache2 version wich comes with Etch is 2.2.3.

And as you can see, all the packages are installed already:

# apt-get install apache2 apache2-doc apache2-mpm-prefork apache2-utils libexpat1 ssl-cert
Reading package lists... Done
Building dependency tree... Done
apache2 is already the newest version.
apache2-doc is already the newest version.
apache2-mpm-prefork is already the newest version.
apache2-utils is already the newest version.
libexpat1 is already the newest version.
ssl-cert is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.

My system is up to date as i do an apt-get update/upgrade every single day.

httpd -V also gives me:Apache 2.2.3
__________________
Hans

MrHostman | Managed Hosting

Last edited by Hans; 6th September 2008 at 13:17.
Reply With Quote
  #4  
Old 6th September 2008, 12:45
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,748 Times in 2,579 Posts
Default

Seems to be a problem with graceful restarts:
http://www.linuxquestions.org/questi...riptor-593925/
https://issues.apache.org/bugzilla/s...g.cgi?id=42829
Do you get the same error when you run a normal restart or a stop and then start?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #5  
Old 6th September 2008, 13:25
Hans Hans is offline
Moderator
 
Join Date: Dec 2005
Location: Montfoort, The Netherlands
Posts: 2,263
Thanks: 216
Thanked 649 Times in 295 Posts
Default

Thanks Falko,
That are the articles i found too. For this reason i think indeed it's a bug in Apache 2.2.3.

Quote:
Originally Posted by falko View Post
Do you get the same error when you run a normal restart or a stop and then start?
When i do a normal start/stop or restart i don't have any error in /var/log/apache2/error.log.
__________________
Hans

MrHostman | Managed Hosting
Reply With Quote
  #6  
Old 7th September 2008, 17:55
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,748 Times in 2,579 Posts
Default

According to http://www.linuxquestions.org/questi...riptor-593925/ , this is also a problem with 2.2.6 (and probably 2.2.4 and 2.2.5 as well).
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #7  
Old 8th September 2008, 13:34
Hans Hans is offline
Moderator
 
Join Date: Dec 2005
Location: Montfoort, The Netherlands
Posts: 2,263
Thanks: 216
Thanked 649 Times in 295 Posts
Default

I guess i have to wait until Debian Lenny comes out. I've read Lenny will come with Apache2 version 2.2.9.
__________________
Hans

MrHostman | Managed Hosting
Reply With Quote
  #8  
Old 31st August 2010, 20:25
ejmarten ejmarten is offline
Junior Member
 
Join Date: Aug 2010
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Try different MPM module

Have you tried installing apache with a different MPM module? If your website/webapp uses a connector to a multithreaded backend (ajp13?), you might want to try using the worker MPM.

#apt-get install apache2 apache2-doc apache2-mpm-worker apache2-utils libexpat1 ssl-cert

The error message itself might be a bug:
https://issues.apache.org/bugzilla/s...g.cgi?id=42829

The work around is to do a hard restart instead of a graceful restart when using mod_prefork.

If you have apache managing multiple ajp13 backend connections, I would try running mod_worker, not as a workaround to this bug, but for better performance and reliability.
Reply With Quote
  #9  
Old 30th June 2014, 19:58
Buddhiran Buddhiran is offline
Junior Member
 
Join Date: Jun 2014
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
 
Default Bad file descriptor: apr_socket_accept

Please check your virtual host has correct parameters. If you have wrong parameters there you will get the same exception.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Error on install igbe Installation/Configuration 7 28th February 2007 23:55
Problems with Apache and Updating Jubalint Installation/Configuration 2 21st May 2006 20:50
Mysterious Install Problem tgansert Installation/Configuration 5 9th May 2006 16:35
setup fails on debian 3.1 dtrumbower Installation/Configuration 7 7th March 2006 14:42
Update to 2.2.0 question brianetilley Installation/Configuration 10 4th March 2006 18:02


All times are GMT +2. The time now is 19:28.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.