0

Output when trying "apache2 restart"

* Restarting web server apache2                                                
[Thu Feb   09 00:55:09 2012] [warn] NameVirtualHost 71.19.144.240:80 has no VirtualHosts
[Thu Feb 09 00:55:09 2012] [warn] NameVirtualHost *:0 has no VirtualHosts
[Thu Feb 09 00:55:09 2012] [warn] NameVirtualHost *:80 has no VirtualHosts
[Thu Feb 09 00:55:09 2012] [warn] NameVirtualHost xxx.xxx.xxx:80 has no VirtualHosts
[Thu Feb 09 00:55:09 2012] [warn] NameVirtualHost *:0 has no VirtualHosts
[Thu Feb 09 00:55:09 2012] [warn] NameVirtualHost *:80 has no VirtualHosts
(98)Address already in use: make_sock: could not bind to address [::]:80
                                                                     [fail]

httpd.conf file: GNU nano 2.2.2 File: httpd.conf

Listen 80
NameVirtualHost *:80

<VirtualHost *>
ServerName www.xxxxx.net
DocumentRoot /srv/www/xxxx.net/public_html/
</VirtualHost>


<VirtualHost *>
ServerName www.xxxxx.com
DocumentRoot /srv/www/xxxxxx.com/public_html/
</VirtualHost>
0

1 Answer 1

0
Address already in use: make_sock: could not bind to address [::]:80

This means something is already running under port 80. I am guessing you are using

/etc/init.d/apache2 restart

to try to restart the server. Try stopping the service first just to debug.

Again from ubuntu distribution perspective:

NameVirtualHost *:80
Listen 80

should go under

/etc/apache2/ports.conf

and virtual host configuration options

<VirtualHost *:80>
ServerName www.xxxxx.com
DocumentRoot /srv/www/xxxxxx.com/public_html/
</VirtualHost>

should go under a distinct file under /etc/apache2/sites-available which is later on symlinked to /etc/apache2/sites-enabled so that apache sees if in apache's default ubuntu configuration.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .