httpd not running, trying to start

After rebooting my Linux server Apache fails to start. When trying to start with either apachectl or httpd I’ll come across the following message:

httpd not running, trying to 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
no listening sockets available, shutting down
Unable to open logs

In my particular case, this stinker of an issue arises due to my SSL Certificate requiring a pass phrase. Since during reboot that pass phrase was not provided, Apache could not start.

So, after seeing the error above you’ll need to check what is currently listening to port 80:

netstat -lnp | grep :80

If you see a process running, kill it using:

kill -9 pid (where pid is the numeric process returned above)

You can now try and start/restart; I use:

/usr/sbin/apachectl graceful

Then, you’ll see that Apache is now trying to successfully start. You’ll see something like this:

httpd not running, trying to start
Apache/2.2.3 mod_ssl/2.2.3 (Pass Phrase Dialog)
Some of your private key files are encrypted for security reasons.
In order to read them you have to provide the pass phrases.

Here is where you provide the prass phrase.

I think the next thing to do is to remove the pass phrase from my SSL Cert (there’s a good writeup for that which I need to dig up for this post), but in the meantime, this is how it’s handled.

Post written by Ed Reckers

Founder and lead web development consultant at Red Bridge Internet : San Francisco WordPress Developers and Consultants.

One Response to “httpd not running, trying to start”

  1. liuyu

    thx and
    what the dif about APACHE AND APACHECTL?

Leave a Reply