Httpd: "Invalid argument: alloc_listener: failed to get a socket for (null)"
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Httpd: "Invalid argument: alloc_listener: failed to get a socket for (null)"
EDIT: Post is rewritten to give info about the problem using 13/current "httpd apr apr-util" and older kernel (in my situation: 2.6.24)
Symptoms:
Code:
# apachectl start
[Wed Sep 16 20:37:56 2009] [crit] (22)Invalid argument: alloc_listener: failed to get a socket for (null)
Syntax error on line 40 of /etc/httpd/httpd.conf:
Listen setup failed
After installing "httpd apr apr-util" using 13/current im getting this:
Code:
# apachectl start
[Wed Sep 16 20:37:56 2009] [crit] (22)Invalid argument: alloc_listener: failed to get a socket for (null)
Syntax error on line 40 of /etc/httpd/httpd.conf:
Listen setup failed
What happens if you start apache with sh /etc/rc.d/rc.httpd start
Are you actually root when using apachectl?
Both apachectl and rc.httpd work on my end with Slackware64-13.0 and and 32bit 13.0 with the same application versions you have.
What are you editing the config file with? Perhaps it placed some junk on the line. Try blowing out line 40 and retyping Listen 80. Not sure which editors do or do not leave junk behind, I do know nano works.
Is just a script that execute "apachectl -k start", so its give the same error.
And ofc doing it as root.
Im using "pico" for editing, but shouldnt be the problem as a fresh install without editing any config files gives the same error.
Just to confirm, i commented "Listen 80" and wrote it again on line 41 getting same error with the line referance 41.
The issue is related to three kernel calls that are used in apr-1.3.8-1: accept4(), dup3() and epoll_create1(). Without these calls, apache is unable to start.
EDIT 2: And the above is solving the problem. Downloaded "slackware-12.2/slackware/l/apr-1.3.3-i486-1.tgz", installed it and the problem is gone, httpd is working
So the problem must be in "apr-1.3.8"?
EDIT 2: replacing apr-1.3.8 with apr-1.3.3-i486-1 solves the problem on both my servers...
EDIT 3: As im getting this problem on 3 different machines, there must be others having same problem?
I'm thinking it could be related to kernel versions. Which kernel version are you running? Are you using the official kernel from Slackware 13.0/current? Can you verify that?
Tbh i feel abit shamed for not remember last time i upgraded my kernels.
But they where official huge-smp/smp kernels from -current at the time they arrived
Linux Alpha 2.6.24.4-smp #2 SMP
Linux Bravo 2.6.24.5-smp #2 SMP
Linux Charlie 2.6.23.16-smp #2 SMP
Will do a restart with up2date kernel when i got time to go onsite to be sure they get back-up after reboot.
EDIT 2: And the above is solving the problem. Downloaded "slackware-12.2/slackware/l/apr-1.3.3-i486-1.tgz", installed it and the problem is gone, httpd is working
So the problem must be in "apr-1.3.8"?
EDIT 2: replacing apr-1.3.8 with apr-1.3.3-i486-1 solves the problem on both my servers...
EDIT 3: As im getting this problem on 3 different machines, there must be others having same problem?
Same issue here. Thanks nirox!! I replaced apr-1.3.8-i486-1.txz with apr-1.3.8-i486-1_slack12.2.tgz and issue resolved. It works now!!
Ummm, I'm a little confused. Does anyone know why this works? Is it a kernel issue or a package issue? I seem to be getting the same thing with httpd-2.2.22, apr-1.4.5, and apr-util-1.4.1. If its a kernel issue should I just use a lower version of apache as my VPS provider is being a bit dense on getting a 3.0 kernel installed (current kernel 2.6.26). Any help would be greatly appreciated as it doesn't seem to be located in the apache docs as far as I can tell.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.