Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I set up a site a while ago to work on port 8080, and copying the configuration, changing only the root directory and port, I expected to have another site served on port 8082, but it fails with: Error 102 (net::ERR_CONNECTION_REFUSED): The server refused the connection.

Here are all the relevant config files, I can post more if there is something missing.

sysadmin@cpms-hub:~$ cat /etc/apache2/sites-enabled/default 
<VirtualHost *:8080>
        ServerAdmin webmaster@localhost

        DocumentRoot /var/www/stocker/app/webroot
        <Directory />
                Options FollowSymLinks
                AllowOverride All
        </Directory>

</VirtualHost>
sysadmin@cpms-hub:~$ cat /etc/apache2/sites-enabled/website 
<VirtualHost *:8082>

        ServerAdmin billy@itaccess.org

        DocumentRoot /var/www/website
        <Directory />
                Options FollowSymLinks
                AllowOverride All
        </Directory>

</VirtualHost>
sysadmin@cpms-hub:~$ ls -la /etc/apache2/sites-enabled/
total 8
drwxr-xr-x 2 root root 4096 Oct  3 15:32 .
drwxr-xr-x 7 root root 4096 May  9 16:12 ..
lrwxrwxrwx 1 root root   26 May  9 16:12 000-default -> ../sites-available/default
lrwxrwxrwx 1 root root   36 Oct  3 15:30 default -> /etc/apache2/sites-available/default
lrwxrwxrwx 1 root root   22 Aug 15 23:41 hub -> ../sites-available/hub
lrwxrwxrwx 1 root root   36 Oct  3 15:32 website -> /etc/apache2/sites-available/website
sysadmin@cpms-hub:~$ ls -la /etc/apache2/sites-available/
total 28
drwxr-xr-x 2 root root 4096 Oct  3 15:29 .
drwxr-xr-x 7 root root 4096 May  9 16:12 ..
-rw-r--r-- 1 root root  257 Aug 15 23:18 default
-rw-r--r-- 1 root root 7469 Feb  7  2012 default-ssl
-rw-r--r-- 1 root root  170 Aug 15 23:30 hub
-rw-r--r-- 1 root root  176 Oct  3 15:44 website
sysadmin@cpms-hub:~$
share|improve this question
    
Did you include the port in your /etc/apache2/ports.conf if it's a debianesque system? –  Alexander Janssen Oct 3 '12 at 19:02
add comment

1 Answer

up vote 3 down vote accepted

Did you set apache to listen on port 8082? You'll need to add an additional Listen statement in an appropriate configuration file.

Listen 8080 
Listen 8082
share|improve this answer
    
thanks - that did it –  Billy Moon Oct 3 '12 at 19:18
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.