Hey,

We have an account with RackSpace and nobody has answered me from them yet. So I am asking here because let's face it ... we are fast at responding.

I have two IP addresses assigned to a machine. One being 72.x.x.113 and the other being 72.x.x.33.

I want to setup IIS on 72.x.x.33 and Apache2 on 72.x.x.113. Both on port 80. How do I do this? If I startup Apache2 (in the config I have Listen command only listening on 72.x.x.113:80) and it's all good. When I go to the web and type in 72.x.x.113 it shows up with the apache page. And when I go to 72.x.x.33 it isn't available (which is because IIS is shutdown).

Now when I start IIS it starts but no site works. All of them have the red stop sign by them and when I try to manually start it says it is being blocked by another process.

Any ideas?

Chad

    you cant have 2 servers listening on the same port.

      They aren't the same IP. I know you can't have the same port on the same system having two systems listening to it. However, the machine has two IP's and one being IIS and the other being Apache.

      Get what I mean?
      How do I make IIS start up and don't do some spooling? I can't find anywhere that describes how to do this. Oh and it's IIS6, Server 2003.

      Chad

        even still, if these two ip's point to the same machine i dont see how you can have both servers listening on the same port.

        of course, im no networking guy, but it just doesnt make sense.

          I am not a networking guy either but was asked to make it happen. Theoretically it should work fine. Apache2 fires up and only responds to the 72.x.x.113 address and IIS only responds to 72.x.x.33. However, they can't run together. I think it's a IIS issue, but don't know enough to fix it.

          Anyone have any ideas?
          Chad

            You should be able to set the ip address and port that you want IIS to listen to.
            In the IIS manger, right click on default website (or whatever webfolder you have running your site). Then on the Web Site Tab, you should see the IP Address Field.

            Not sure if this will fix your problem, I haven't tried running both Apache and IIS on teh same box, but Good Luck.

              15 days later

              I was facing the same problem, and ran across this place when looking for the answer. Since I found it i thought I would tell you all. Below is the section of another forum that contains the answer. I tried it and now i am running iis6 and apache2 with diff IPs but both on port 80. Works Great, and its all iis6's fault:

              I just ran across this earlier today while looking for something else.
              It is from O'Reilly's Windows Server Hacks, March 2004.

              It sounds like your situation.

              Hack 60 - Run Other Web Servers

              Here's how to run another web server, in addition to IIS, on the same machine without conflict over who gets port 80.

              Ever have problems when you try to run more than web server on the same machine? Or have you run some other web-enabled software together with IIS, only to find that one or both of them break? The problem here is socket pooling, a feature of IIS 5 and later that causes IIS to bind to all IP addresses configured on the server, even on a multihomed machine with more than one network card. The funny thing is that socket pooling even binds IIS to IP addresses that aren't yet assigned to any web site on the machine even if there's no Default Web Site configured to respond to All Unassigned IP addresses by default. This behavior not only prevents other HTTP software from coexisting with IIS, but it can also cause IIS to return errors to clients. A workaround that sometimes works is to set the HTTP port number for the other software to something nonstandard, such as 8099, but that won't work in most cases unless clients using that software also use that port to connect. By default, however, IIS won't let any other application listen on port 80 (the standard HTTP port), even if it's listening on an IP address that is not used by IIS.

              Disabling Socket Pooling in IIS 5

              Socket pooling is enabled on IIS 5, by default, but it can be disabled to allow other HTTP-enabled third-party software to run side-by-side with IIS, each responding to requests sent to different IP addresses. There are two ways to do disable socket pooling in IIS 5. First, you can edit the metabase by using the MetaEdit utility [Hack #54]. By default, the setting for socket pooling is defined in the metabase schema, but you can use MetaEdit to create a new metabase key called DisableSocketPooling in the location /LM/W3SVC and assign it the value of true (1). In other words, the default value for DisableSocketPooling in the schema is false (0), which means it is false to say socket pooling is enabled. Don't you love those double negatives?

              The other way to disable socket pooling is to use the adsutil.vbs script included in C:\Inetpub\adminscripts [Hack #59]. Type the following command:

              cscript C:\Inetpub\adminscripts\adsutil.vbs set w3svc/disablesocketpooling true

              You should see the response DisableSocketPooling: (BOOLEAN) True.

              Now, stop IIS services by typing net stop iisadmin /y (which also stops the dependent WWW Publishing Services). Then, restart them by typing net start w3svc (which also starts the parent IIS Admin Service). Socket pooling is now disabled. If you like, you can use MetaEdit to verify that the key has been added.

              Disabling Socket Pooling in IIS 6

              The DisableSocketPooling metabase key is also valid in IIS 6 but, interestingly enough, changing it from 0 to 1 doesn't do anything. That's because socket-pooling functionality has been moved from the Winsock HTTP listener used in IIS 5 to the new kernel mode HTTP driver (http.sys). As a result, you have to use a nifty little utility called Httpcfg.exe to disable it.

              This utility is found in the /Support/Tools folder on your Windows Server 2003 product CD, so begin by inserting this CD and double-clicking on /Support/Tools/SUPTOOLS.MSI to install these tools on your server. Next, open a command prompt and type httpcfg set iplisten -i w.x.y.z:n to add IP address w.x.y.z and port number n to the IP inclusion list for http.sys. This inclusion list specifies which IP addresses http.sys listens on and is initially empty by default, which means that IIS listens to all IP addresses (not none, as you might suspect). However, once you add an IP address and port number (i.e., a socket) to the inclusion list, http.sys will now listen only on the specified socket and ignore all others, leaving them available for other applications to listen on. You can add as many sockets to the inclusion list as you choose, and you can display a list of listening sockets at any time by typing httpcfg query iplisten at a command prompt.

              Don't forget to restart IIS after modifying the list, because http.sys reads this list only on startup. You don't have to restart all IIS services, only the HTTP Service (a subcomponent of the WWW Publishing Services and a service not displayed in the Services console). To restart the HTTP Service, type net stop http /y to stop it and net start w3svc to start it. Note that if you have problems afterwards starting any web sites on your IIS machine, you probably forgot to add their IP addresses to the inclusion list.

              Other Reasons to Disable Socket Pooling

              If running third-party HTTP software together with IIS isn't your cup of tea, there are other reasons why you might want to disable socket pooling. The bandwidth-throttling feature of IIS that is configured through Internet Services Manager throttles bandwidth to all web sites running on IIS equally. The same is true of the performance-tuning settings configured through the GUI. If you prefer to configure these settings on a per-site basis, you have to disable socket pooling before it will work. This is not obvious from the GUI, which presents separate throttling and performance options for each site. The fact that these features don't work as advertised has been an open secret among the IIS community for a long time. They work only when socket pooling is disabled, and it's enabled by default.

              Let me know if it works for you.
              Thanx,
              radar101

                Thanks for the reply, I have resolved this many times over. The IIS installation was bad and I had to reload the server and then I disabled the spooling and it was smooth sailing after that. Then I just had Apache listen on the IP I wanted it to do and it was fine.

                Thanks for the response though,
                Chad R. Smith
                50 Marketing
                www.50marketing.com

                  how did you configure the httpd file to allow acces from outside the network to the domain name of the appache server. Mine just gives me "bad host name" or something like that.

                    Radar,

                    I will send you the httpd file I am using when I get to work tomorrow. Hang in there,
                    Chad

                      Write a Reply...