Article ID: 6283, created on Apr 29, 2009, last review on May 1, 2014

Synopsis

When you are trying to start Apache Web server you get the following error in the console and in error_log:

"(98)Address already in use: make_sock: could not bind to address [::]:443
no listening sockets available, shutting down"

(It is also possible that error states about 80 port.)

Cause

This error means that some other process already uses 443 (80) port and Apache cannot bind to it.

Resolution

First of all make sure that "Listen" directive is specified only once in Apache configuration for one port. Chcek the httpd.conf and conf.d/* files in order to find it (on some OSes, like SUsE also /etc/apache2/* should be chacked).


Next, try to find which process uses the port with the following command:

/usr/sbin/lsof -i | grep http
httpd 24717 apache 4u IPv6 9672930 TCP *:https (LISTEN)


This command shows that "TCP *:https " port is used by "httpd" process with PID 24717.

Such problem may occur if Apache failed to stop properly, you need to kill this process and start
Apache again. If you see that some another program uses 443 port, you need to find where it was
started from and find out what is it because it can be some malicious script. Run:

cat /proc/24717/cmdline
/usr/sbin/httpd-kgraceful


to find a command line this process was started with. (24717 is the process' PID).
Then kill the process.

Email subscription for changes to this article
Save as PDF