Two apache servers using same port?

JJ Edgar VI asked:

so I have two apache servers on the same system.

Basically what I’m trying to figure out is if since I have 2 different IPs running on my system is it possible to have two different apache servers running on different IPs but using the default port(80) so the user doesn’t have to specify the port in the address bar?

What I am trying to do is make it so that if the users visits: —-> Apache Server 1 running on —-> Apache Server 2 running on

This would make it so that each domain would point to different apache servers but on the same system.

Thank you, JJ Edgar

My answer:

You can control which IP address Apache listens on using the Listen directive.

Just make sure that each server’s configuration specifies only the IP addresses you want to use for that particular server.

For instance:

Server 1:


Server 2:


Any <VirtualHost> directives you use must also specify their IP addresses, rather than using the wildcard *.

See the Apache documentation for further details.

View the full question and any other answers on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.