LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (http://www.linuxquestions.org/questions/linux-server-73/)
-   -   Apache Webserver on Slackware - Failed to Start Apache - 'no listening sockets .." (http://www.linuxquestions.org/questions/linux-server-73/apache-webserver-on-slackware-failed-to-start-apache-no-listening-sockets-760974/)

CCTVGuru 10-10-2009 09:20 AM

Apache Webserver on Slackware - Failed to Start Apache - 'no listening sockets .."
 
Hi, Everyone,

Can I ask for documentation and help for resolving my problem to start Apache Webserver on Slackware 12;

The module has been installed successfully and one virtual host created / listed, but at the point of trying "Apache Start" the reply is referring to "no sockets available"..


Quote:

Module Index
Error

--------------------------------------------------------------------------------

Failed to start apache :
/usr/local/apache2/bin/apachectl start :
(98)Address already in use: make_sock: could not bind to address [::]:80
(98)Address already in use: make_sock: could not bind to address 0.0.0.0:80
no listening sockets available, shutting down
Unable to open logs
Logically, somewhere in teh setting procedures I have omitted to specify the binding IP address and most probably this causes the problem.

If somewhere in the forum the same issue has been dealt with, I would appreciate directions to topics and tuitorials.

I have kept the default server as generated during the installation, and created 2 virtual hosts (one is per DNS name, the other is per IP address (matching the registered DNS name)).

Thank you in advance,

:study:

unSpawn 10-10-2009 11:40 AM

Quote:

Originally Posted by CCTVGuru (Post 3714527)
Code:

(98)Address already in use: make_sock: could not bind to address [::]:80

"In use" means something is listening on port TCP/80 already. Could be a remnant of earlier experimentation to get Apache to run, could be something else. Kill it before starting Apache. If unsure, as root, check with 'lsof -i tcp:80' or 'fuser -n tcp 80' to see what's listening on the port and needs to be killed.

millergroup 10-10-2009 09:41 PM

Do this. The PID for httpd is still running even though apache looks dead.

From the command line ~# killall -9 httpd
~# apachectl start
or ~# /etc/init.d/httpd start



Hope this helps.

CCTVGuru 10-11-2009 12:54 AM

Thank yo millergroup and unSpawn,

Noted. In meantime I have been reading related topics and changed the listening port to 8080 instead standard 80.
Now, by typing my IP address http://123.456.789.123 and http://123.456.789.123:8080 I can open up the test index file ("It Works") but the next task for me is to open the www.servername.com in the browser.
By doing that it gives me a search page.
Of course, I have not uploaded any content as yet, but I will make a test html page and upload it to the related content folder.

I hope to resolve this stage successfully, if any pointing to sequence of procedures and pointing to topics is given to me I would be grateful!

Best Regards!

Wim Sturkenboom 10-11-2009 02:14 AM

There is no need to change to 8080. As unSpawn indicated, the address is already in use. You can stop Apache in Slackware with /etc/rc.d/rc.httpd stop and start it with /etc/rc.d/rc.httpd start; do this as root.

With regards to access via the domain name. You can add the domain to /etc/hosts


All times are GMT -5. The time now is 09:50 AM.