Forum Moderators: phranque
That's fair enough but how can I configure apache to run from two IP addresses?
I have two virtual servers on one dedicated server. They all use the same IP address.
Current:
IP 111.111.111.111
Virtual servers: widgets.co.uk, widgetspares.co.uk
What they say I should do is to set the server up to accept both IP's:
IP 111.111.111.111 or IP 222.222.222.222
Virtual servers: widgets.co.uk, widgetspares.co.uk
How do I do that?
I can't see where in the httpd.conf I can do that. All I have in that file is:
------------------------------------
Listen 111.111.111.111
NameVirtualHost 111.111.111.111
<VirtualHost 111.111.111.111>
ServerName widgets.co.uk
(other stuff)
</VirtualHost>
<VirtualHost 111.111.111.111>
ServerName widgetspares.co.uk
(other stuff)
</VirtualHost>
-----------------------------------
Do I just duplicate the Listen, and Virtual Host 111 entries? Set the duplicate to 222.?
What about the linux network configuration? I need to set this up for two IP's and I also need to change the gateway and DNS settings.
Server Apache 2.0.52
Linux Centos 4.3
[edited by: Frank_Rizzo at 10:49 am (utc) on July 13, 2006]
Listen 127.0.0.1:80
Listen 192.168.0.1:80
Or just simply
Listen 80
and Apache will listen on all available network interfaces.
Added:
Do your virtual hosts like this:
NameVirtualHost *:80
<VirtualHost *:80>
ServerName widgets.co.uk
(other stuff)
</VirtualHost>
[edited by: zCat at 10:56 am (utc) on July 13, 2006]