How to setup Apache on a Windows 2008 Server with IIS?
This article shows you how to configure IIS and install Apache on a Windows 2008 server. In this example the Microsoft Windows 2008 Server will be configured with two IP addresses bound to the single NIC. The intention is to let IIS run on the primary IP Address of 192.168.0.10 and Apache to run on the second IP Address 192.168.0.11
To verifiy you have two IP addresses open a command prompt and type ipconfig. The results should indicate that at least two IP Addresses have been bound.
Configure IIS to bind it to one IP Address
By default IIS listens on port 80 and 443 on all IP Address.
netsh http>add iplisten 192.168.0.10
IP address successfully added
netsh http>show iplisten
IP addresses present in the IP listen list:
To make IIS listen to a specific port use the syntax: add iplisten 0.0.0.0:XXXX. Replace XXXX with the port number, for example, 8080.
It is also necessary to edit the bindings of each site inside IIS Manager.Â To do this run IIS Manager and select "edit bindings" of the "Default Web Site" and ensure the IP Address isn't a "*" otherwise it will still listen on all addresses. In this example we simply change the IP Address to 192.168.0.10
Install Apache on the Windows 2008 Server
Download the Apache Server from www.apache.org and install.
Once the installation is complete edit the httpd.conf file from the Apache/conf directory and edit the line starting ServerName.
If this line is commented out on your httpd.conf then look for the line starting Listen and change that
In this example we have told Apache to listen on port 80 on the IP Address of 192.168.0.11