Page 1 of 1

HTTPD Fail to START

Posted: Sun Sep 13, 2015 8:38 pm
by vhoover
the HTTP daemon won't start and as a result the nagios gui is unavailable. When attempting to start the daemon I receive the following error:

Code: Select all

Starting httpd: (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

Re: HTTPD Fail to START

Posted: Mon Sep 14, 2015 8:54 am
by tmcdonald
What command are you using to start the httpd daemon? Does a service httpd restart clear it? It definitely sounds like something is already taking port 80, possibly the httpd process is already running?

Re: HTTPD Fail to START

Posted: Mon Sep 14, 2015 11:53 am
by vhoover
When attempting to clear it I get a failed message. Attached is the output from the service stop, start, restart, & the netstat command.

Re: HTTPD Fail to START

Posted: Mon Sep 14, 2015 1:05 pm
by tgriep
Try and force httpd to stop by running the following.

Code: Select all

killall -9 httpd
After that, make sure the pid file is removed from the system. Run this to remove it.

Code: Select all

rm /var/run/httpd/httpd.pid
Then start httpd

Code: Select all

service httpd start
Take a look in the /var/log/httpd/error_log file if this fails.

Re: HTTPD Fail to START

Posted: Mon Sep 14, 2015 1:15 pm
by vhoover
That solved it, thanks. I will make note of this, should (knock on wood) happen again.

Re: HTTPD Fail to START

Posted: Mon Sep 14, 2015 1:18 pm
by tgriep
That is good to hear. I'll close the post for you.