Networking Forums

Networking Forums > Computer Networking > Windows Networking > Which NIC Will Windows Use?

Reply
Thread Tools Display Modes

Which NIC Will Windows Use?

 
 
Doug Thews
Guest
Posts: n/a

 
      07-01-2004, 11:12 PM
I have a Windows 2003 Server with two separate NICs and 2 separate IPs (the
NICs do not support teaming). Both connect to the same gateway, but are
actually on different private subnets (don't ask me why it was set up this
way ... probably one was private and one was public at some point in this
server's infancy).

Anyway, I was wondering how Windows determines which NIC to use to send
packets out? Let's say a generic request for a TCP request on port 80 made
by a web service app is made. Which NIC will the OS choose? Will it be the
same all the time (the one with the lowest bind number)? Also, does this
same logic apply to Windows 2000/XP?

--
Doug Thews
Director, Customer Solutions
D&D Consulting Services
----------------
Visit my Tech Blog at:
http://www.ddconsult.com/blogs/illuminati/




 
Reply With Quote
 
 
 
 
Alun Jones [MSFT]
Guest
Posts: n/a

 
      07-01-2004, 11:49 PM
"Doug Thews" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Anyway, I was wondering how Windows determines which NIC to use to send
> packets out? Let's say a generic request for a TCP request on port 80

made
> by a web service app is made. Which NIC will the OS choose? Will it be

the
> same all the time (the one with the lowest bind number)? Also, does this
> same logic apply to Windows 2000/XP?


The NIC is chosen on the basis of what's in the routing table. A packet
will go out based on which NIC is closest to the target IP address. This
does mean that you will sometimes see packets sourced at one NIC's IP
address going through another NIC, because that NIC is closer to the target
address.

Alun.
~~~~


 
Reply With Quote
 
Phillip Windell
Guest
Posts: n/a

 
      07-02-2004, 01:50 PM
"Doug Thews" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> I have a Windows 2003 Server with two separate NICs and 2 separate IPs

(the
> NICs do not support teaming). Both connect to the same gateway, but are
> actually on different private subnets (don't ask me why it was set up this
> way ... probably one was private and one was public at some point in this
> server's infancy).


Well in this particular case only one will work properly. The Default
Gateway *must* be in the same subnet as the Interface. So since you say
that they are different subnets but yet the same gateway, that means one has
an incompatible gateway and will not do anything outside of it own subnet.

When things are correctly configured,..it is the routing table that makes
the decision for which interface to use based on routes entered into the
table. The Default Gateway is only for "unspecified routes",...there can bo
only **one**. Other nics must leave theirs blank. You can have only *one*
gateway to an "unknown" location via and "unknown" route. All others must
be "known" destinations via a "known" route. The Internet is always
classified as an "unknown".

--

Phillip Windell [MCP, MVP, CCNA]
www.wandtv.com


 
Reply With Quote
 
Doug Thews
Guest
Posts: n/a

 
      07-03-2004, 04:18 AM
OK, I see. I mis-spoke when I said they were on different subnets. They
are in fact on the same 10.x subnet and they both have the same default
gateway.

Let's say NIC1= 10.100.1.8 and NIC2=10.100.1.49, with the DG for
both=10.100.1.1.

Now, there's nothing special set up in the routing table (from my
perspective), so my question is ... If I have an application that opens a
port 80 connection to a web service (like Amazon's web services ... on a
206.x.x.x address), how does Windows determine which NIC should be used to
send the packets? My guess is that in this case, the card with the lowest
binding number will always get called.

Thanks in advance for your help.

--
Doug Thews
Director, Customer Solutions
D&D Consulting Services
----------------
Visit my Tech Blog at:
http://www.ddconsult.com/blogs/illuminati/



"Phillip Windell" <@.> wrote in message
news:(E-Mail Removed)...
> "Doug Thews" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
> > I have a Windows 2003 Server with two separate NICs and 2 separate IPs

> (the
> > NICs do not support teaming). Both connect to the same gateway, but are
> > actually on different private subnets (don't ask me why it was set up

this
> > way ... probably one was private and one was public at some point in

this
> > server's infancy).

>
> Well in this particular case only one will work properly. The Default
> Gateway *must* be in the same subnet as the Interface. So since you say
> that they are different subnets but yet the same gateway, that means one

has
> an incompatible gateway and will not do anything outside of it own subnet.
>
> When things are correctly configured,..it is the routing table that makes
> the decision for which interface to use based on routes entered into the
> table. The Default Gateway is only for "unspecified routes",...there can

bo
> only **one**. Other nics must leave theirs blank. You can have only *one*
> gateway to an "unknown" location via and "unknown" route. All others must
> be "known" destinations via a "known" route. The Internet is always
> classified as an "unknown".
>
> --
>
> Phillip Windell [MCP, MVP, CCNA]
> www.wandtv.com
>
>



 
Reply With Quote
 
Bill Grant
Guest
Posts: n/a

 
      07-04-2004, 12:23 AM

Despite what the settings on a NIC may seem to indicate, you can have
only one default gateway per machine, not one per interface. If you
configure more than one, performance will be unpredictable. RRAS in
particular does odd things when multiple gateways are configured.

In your case, I would just disable one NIC. Having two won't give you
any advantages and may cause you grief.

"Doug Thews" <(E-Mail Removed)> wrote in message
news:#(E-Mail Removed)...
> OK, I see. I mis-spoke when I said they were on different subnets. They
> are in fact on the same 10.x subnet and they both have the same default
> gateway.
>
> Let's say NIC1= 10.100.1.8 and NIC2=10.100.1.49, with the DG for
> both=10.100.1.1.
>
> Now, there's nothing special set up in the routing table (from my
> perspective), so my question is ... If I have an application that opens a
> port 80 connection to a web service (like Amazon's web services ... on a
> 206.x.x.x address), how does Windows determine which NIC should be used to
> send the packets? My guess is that in this case, the card with the lowest
> binding number will always get called.
>
> Thanks in advance for your help.
>
> --
> Doug Thews
> Director, Customer Solutions
> D&D Consulting Services
> ----------------
> Visit my Tech Blog at:
> http://www.ddconsult.com/blogs/illuminati/
>
>
>
> "Phillip Windell" <@.> wrote in message
> news:(E-Mail Removed)...
> > "Doug Thews" <(E-Mail Removed)> wrote in message
> > news:(E-Mail Removed)...
> > > I have a Windows 2003 Server with two separate NICs and 2 separate IPs

> > (the
> > > NICs do not support teaming). Both connect to the same gateway, but

are
> > > actually on different private subnets (don't ask me why it was set up

> this
> > > way ... probably one was private and one was public at some point in

> this
> > > server's infancy).

> >
> > Well in this particular case only one will work properly. The Default
> > Gateway *must* be in the same subnet as the Interface. So since you say
> > that they are different subnets but yet the same gateway, that means one

> has
> > an incompatible gateway and will not do anything outside of it own

subnet.
> >
> > When things are correctly configured,..it is the routing table that

makes
> > the decision for which interface to use based on routes entered into the
> > table. The Default Gateway is only for "unspecified routes",...there

can
> bo
> > only **one**. Other nics must leave theirs blank. You can have only

*one*
> > gateway to an "unknown" location via and "unknown" route. All others

must
> > be "known" destinations via a "known" route. The Internet is always
> > classified as an "unknown".
> >
> > --
> >
> > Phillip Windell [MCP, MVP, CCNA]
> > www.wandtv.com
> >
> >

>
>



 
Reply With Quote
 
Phillip Windell
Guest
Posts: n/a

 
      07-05-2004, 02:33 PM
If you truely need two IP#s, then run both IP#s on the same Nic. Get rid of
the second Nic.


--

Phillip Windell [MCP, MVP, CCNA]
www.wandtv.com


"Doug Thews" <(E-Mail Removed)> wrote in message
news:%(E-Mail Removed)...
> OK, I see. I mis-spoke when I said they were on different subnets. They
> are in fact on the same 10.x subnet and they both have the same default
> gateway.
>
> Let's say NIC1= 10.100.1.8 and NIC2=10.100.1.49, with the DG for
> both=10.100.1.1.
>
> Now, there's nothing special set up in the routing table (from my
> perspective), so my question is ... If I have an application that opens a
> port 80 connection to a web service (like Amazon's web services ... on a
> 206.x.x.x address), how does Windows determine which NIC should be used to
> send the packets? My guess is that in this case, the card with the lowest
> binding number will always get called.
>
> Thanks in advance for your help.
>
> --
> Doug Thews
> Director, Customer Solutions
> D&D Consulting Services
> ----------------
> Visit my Tech Blog at:
> http://www.ddconsult.com/blogs/illuminati/
>
>
>
> "Phillip Windell" <@.> wrote in message
> news:(E-Mail Removed)...
> > "Doug Thews" <(E-Mail Removed)> wrote in message
> > news:(E-Mail Removed)...
> > > I have a Windows 2003 Server with two separate NICs and 2 separate IPs

> > (the
> > > NICs do not support teaming). Both connect to the same gateway, but

are
> > > actually on different private subnets (don't ask me why it was set up

> this
> > > way ... probably one was private and one was public at some point in

> this
> > > server's infancy).

> >
> > Well in this particular case only one will work properly. The Default
> > Gateway *must* be in the same subnet as the Interface. So since you say
> > that they are different subnets but yet the same gateway, that means one

> has
> > an incompatible gateway and will not do anything outside of it own

subnet.
> >
> > When things are correctly configured,..it is the routing table that

makes
> > the decision for which interface to use based on routes entered into the
> > table. The Default Gateway is only for "unspecified routes",...there

can
> bo
> > only **one**. Other nics must leave theirs blank. You can have only

*one*
> > gateway to an "unknown" location via and "unknown" route. All others

must
> > be "known" destinations via a "known" route. The Internet is always
> > classified as an "unknown".
> >
> > --
> >
> > Phillip Windell [MCP, MVP, CCNA]
> > www.wandtv.com
> >
> >

>
>



 
Reply With Quote
 
Doug Thews
Guest
Posts: n/a

 
      07-06-2004, 03:27 PM
I was planning on doing that. What I was wondering is how does Windows
decide which NIC/IP to use if they're both the same length away from the
destination (and yes, they obviously will have the same DG). My guess since
all I'm reading is about "umpredictability" is that the OS will pick the
NIC/IP with the highest bind # in the registry that matches the criteria
(i.e. closest to the destination).

--
Doug Thews
Director, Customer Solutions
D&D Consulting Services
----------------
Visit my Tech Blog at:
http://www.ddconsult.com/blogs/illuminati/



"Phillip Windell" <@.> wrote in message
news:%(E-Mail Removed)...
> If you truely need two IP#s, then run both IP#s on the same Nic. Get rid

of
> the second Nic.
>
>
> --
>
> Phillip Windell [MCP, MVP, CCNA]
> www.wandtv.com
>
>
> "Doug Thews" <(E-Mail Removed)> wrote in message
> news:%(E-Mail Removed)...
> > OK, I see. I mis-spoke when I said they were on different subnets.

They
> > are in fact on the same 10.x subnet and they both have the same default
> > gateway.
> >
> > Let's say NIC1= 10.100.1.8 and NIC2=10.100.1.49, with the DG for
> > both=10.100.1.1.
> >
> > Now, there's nothing special set up in the routing table (from my
> > perspective), so my question is ... If I have an application that opens

a
> > port 80 connection to a web service (like Amazon's web services ... on a
> > 206.x.x.x address), how does Windows determine which NIC should be used

to
> > send the packets? My guess is that in this case, the card with the

lowest
> > binding number will always get called.
> >
> > Thanks in advance for your help.
> >
> > --
> > Doug Thews
> > Director, Customer Solutions
> > D&D Consulting Services
> > ----------------
> > Visit my Tech Blog at:
> > http://www.ddconsult.com/blogs/illuminati/
> >
> >
> >
> > "Phillip Windell" <@.> wrote in message
> > news:(E-Mail Removed)...
> > > "Doug Thews" <(E-Mail Removed)> wrote in message
> > > news:(E-Mail Removed)...
> > > > I have a Windows 2003 Server with two separate NICs and 2 separate

IPs
> > > (the
> > > > NICs do not support teaming). Both connect to the same gateway, but

> are
> > > > actually on different private subnets (don't ask me why it was set

up
> > this
> > > > way ... probably one was private and one was public at some point in

> > this
> > > > server's infancy).
> > >
> > > Well in this particular case only one will work properly. The Default
> > > Gateway *must* be in the same subnet as the Interface. So since you

say
> > > that they are different subnets but yet the same gateway, that means

one
> > has
> > > an incompatible gateway and will not do anything outside of it own

> subnet.
> > >
> > > When things are correctly configured,..it is the routing table that

> makes
> > > the decision for which interface to use based on routes entered into

the
> > > table. The Default Gateway is only for "unspecified routes",...there

> can
> > bo
> > > only **one**. Other nics must leave theirs blank. You can have only

> *one*
> > > gateway to an "unknown" location via and "unknown" route. All others

> must
> > > be "known" destinations via a "known" route. The Internet is always
> > > classified as an "unknown".
> > >
> > > --
> > >
> > > Phillip Windell [MCP, MVP, CCNA]
> > > www.wandtv.com
> > >
> > >

> >
> >

>
>



 
Reply With Quote
 
Phillip Windell
Guest
Posts: n/a

 
      07-06-2004, 03:44 PM
"Doug Thews" <(E-Mail Removed)> wrote in message
news:%(E-Mail Removed)...
> destination (and yes, they obviously will have the same DG). My guess

since
> all I'm reading is about "umpredictability" is that the OS will pick the
> NIC/IP with the highest bind # in the registry that matches the criteria


That's about it. Also you can have only one DFG and therefore any
"undefined routes" will follow the nic associated with the DFG in the
Routing Table.

--

Phillip Windell [MCP, MVP, CCNA]
www.wandtv.com



 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[networking] Online Public Chat Tomorrow: TCP/IP in Windows Server 2003 SP1 and Windows XP SP2 Deepak Bansal [MS] Windows Networking 0 06-28-2005 10:30 PM
[networking] Online Public Chat Tomorrow: TCP/IP in Windows Server 2003 SP1 and Windows XP SP2 Deepak Bansal [MS] Windows Networking 0 06-28-2005 10:29 PM
Windows 2003 Server in Windows 2000 Domain Lose Trust Relationship Faisal Sarwar Windows Networking 2 06-20-2005 04:51 AM
Windows 2000 client can't map network drive on windows server 2003 John Xie Windows Networking 1 05-31-2005 04:07 PM
windows 2003 load balancing into existing windows 2000 wlbs. urgent Combfilter Windows Networking 1 12-16-2004 04:01 PM



1 2 3 4 5 6 7 8 9 10 11