1

We have multiple sites in IIS with different IP addresses. This is cool, want different IPs to all go to this server and use the proper site. However I discovered an issue that when the server makes an outgoing connection, I cannot predict which IP it will use. I had to have one client add ALL the IPs to their firewall so that a certain service could communicate with their server. Well now the time has come to add another IP/site to IIS but I had told them they would not need to add any more IPs. So the question is, how can I make Windows Server 2003 use only ONE specific IP for outgoing calls instead of it being unpredictable?

If this is not a good enough description, when I was RDPed into the server and I opened IE and went to 'what is my IP' it was sometimes different which is how I discovered why the one client's firewall was suddenly refusing the connections.

How can I just make outgoing calls originate from a static IP yet still allow multiple IPs pointing to different sites in IIS?

5
  • Just curious: Why is your IIS server connecting to client sites?
    – Chris S
    Mar 10, 2011 at 18:24
  • There is a object inside the ASP.NET app that makes LDAP calls to their AD server for authentication against the web app.
    – MetaGuru
    Mar 10, 2011 at 18:29
  • This doesn't make sense. It should use the primary ip address bound to the network adapter that the traffic is originating from. When you say that "What's my IP" showed something different, what did it show exactly?
    – joeqwerty
    Mar 10, 2011 at 19:15
  • @joeqwerty It just was one IP address one time, and another IP address another time. There are multiple IP addresses assigned to the server. And I am talking about traffic originating from this server.
    – MetaGuru
    Mar 10, 2011 at 19:35
  • @joeqwerty you know, now that I think about it I think the change happened after a co-worker of mine added another IP to the machine, I am wondering if when the new IP was added it became the default for the network adapter, that could very well be what happened...
    – MetaGuru
    Mar 10, 2011 at 21:12

2 Answers 2

1

Have a look at the Metric values in your routing table:

ROUTE PRINT

if you have multiple routes for the same destination, the Metric value determines which route and therefore source IP address is used. A lower Metric value is used first.

You can use the PATHPING command to see which address is used.

ROUTE ADD|DELETE|CHANGE allows you to change the routing table including the metric.

0

You could just remove the default gateway from the adapters you don't want traffic to go through. That would allow traffic to come into any adapter but leave only through the one with the gateway configured.

The issue isn't really an IIS thing, it's more of a TCP\IP stack thing. I don't think you can add that functionality to just IIS without affecting everything else on the machine that uses network connectivity.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .