Help with XP routing tables.

  • Thread starter Thread starter TC
  • Start date Start date
T

TC

Hello,

I need help creating a routeing a perminite routing table that
survives reboots and everything. I know it's route -p add but after
that I'm lost.

My PC has 2 NICs

NIC 1
192.168.42.x subnet 255.255.255.0

NIC 2
192.168.3.x subnet 255.255.255.0

What I need is that all traffic goes though NIC 1
Unless traffic is addrss to anything on NIC 2 or NIC 1 Fails.

Can you help?

Thank you,

TC
 
TC said:
Hello,

I need help creating a routeing a perminite routing table that
survives reboots and everything. I know it's route -p add but after
that I'm lost.

My PC has 2 NICs

NIC 1
192.168.42.x subnet 255.255.255.0

NIC 2
192.168.3.x subnet 255.255.255.0

What I need is that all traffic goes though NIC 1
Unless traffic is addrss to anything on NIC 2 or NIC 1 Fails.

Can you help?

Thank you,

TC

Windows automatically configures the routing table to route traffic
for 192.168.3.x through NIC 2, so you don't need to add a route. Look
for the entry that says:

192.168.3.0 255.255.255.0 192.168.3.x 192.168.3.x

where "192.168.3.x" is the IP address of NIC 2.

That's the equivalent of a command that says:

route -p add 192.168.3.0 mask 255.255.255.0 192.168.3.x

To route all traffic that isn't for 192.168.3.x through NIC 1, look
for (or create) a default route that uses NIC 1:

0.0.0.0 0.0.0.0 192.168.42.y 192.168.42.x

where "192.168.42.x" is the IP address of NIC 1, and "192.168.42.y" is
the IP address of the gateway that connects to NIC 1.

The command to create that default route would be:

route -p add 0.0.0.0 mask 0.0.0.0 192.168.42.y

If NIC 1 is disabled, traffic for 192.168.3.x will automatically use
the default gateway that connects to NIC 1.

I'm not aware of any way to cause traffic for 192.168.3.x to use
anything but NIC 2 if NIC 2 is enabled but fails to work properly.
--
Best Wishes,
Steve Winograd, MS-MVP (Windows Networking)

Please post any reply as a follow-up message in the news group
for everyone to see. I'm sorry, but I don't answer questions
addressed directly to me in E-mail or news groups.

Microsoft Most Valuable Professional Program
http://mvp.support.microsoft.com
 
Windows automatically configures the routing table to route traffic
for 192.168.3.x through NIC 2, so you don't need to add a route. Look
for the entry that says:

192.168.3.0 255.255.255.0 192.168.3.x 192.168.3.x

where "192.168.3.x" is the IP address of NIC 2.

That's the equivalent of a command that says:

route -p add 192.168.3.0 mask 255.255.255.0 192.168.3.x

To route all traffic that isn't for 192.168.3.x through NIC 1, look
for (or create) a default route that uses NIC 1:

0.0.0.0 0.0.0.0 192.168.42.y 192.168.42.x

where "192.168.42.x" is the IP address of NIC 1, and "192.168.42.y" is
the IP address of the gateway that connects to NIC 1.

The command to create that default route would be:

route -p add 0.0.0.0 mask 0.0.0.0 192.168.42.y

If NIC 1 is disabled, traffic for 192.168.3.x will automatically use
the default gateway that connects to NIC 1.

I'm not aware of any way to cause traffic for 192.168.3.x to use
anything but NIC 2 if NIC 2 is enabled but fails to work properly.

What I am having problem with is the fact that when I bring NIC 2 up
everything gets routed accross it. Which is creating headaches for me.

So if I do: route -p add 0.0.0.0 0.0.0.0 192.168.42.y 192.168.42.x

That should fix things?


Thank you,

TC
 
TC said:
What I am having problem with is the fact that when I bring NIC 2 up
everything gets routed accross it. Which is creating headaches for me.

So if I do: route -p add 0.0.0.0 0.0.0.0 192.168.42.y 192.168.42.x

That should fix things?


Thank you,

TC

I suspect that there are default gateways specified for both NIC 1 and
NIC 2. To see, look for "0.0.0.0" entries in the route table.

If there are two entries, then you can force Windows XP to always use
the one for NIC 1 in either of these ways:

1. Remove the default gateway specification from the TCP/IP properties
of the LAN connection associated with NIC 2.

2. Specify metric values for the LAN connections associated with NIC 1
and NIC 2, assigning a lower value to NIC 1. To assign a metric to a
network connection:

a. Open the Network Connections folder.
b. Right click the desired connection.
c. Click Properties | Internet Protocol (TCP/IP).
d. Click Properties | Advanced.
e. Un-check "Automatic metric".
f. Enter a number between 1 and 9999 for the "Interface metric".
--
Best Wishes,
Steve Winograd, MS-MVP (Windows Networking)

Please post any reply as a follow-up message in the news group
for everyone to see. I'm sorry, but I don't answer questions
addressed directly to me in E-mail or news groups.

Microsoft Most Valuable Professional Program
http://mvp.support.microsoft.com
 
I suspect that there are default gateways specified for both NIC 1 and
NIC 2. To see, look for "0.0.0.0" entries in the route table.

If there are two entries, then you can force Windows XP to always use
the one for NIC 1 in either of these ways:

1. Remove the default gateway specification from the TCP/IP properties
of the LAN connection associated with NIC 2.

2. Specify metric values for the LAN connections associated with NIC 1
and NIC 2, assigning a lower value to NIC 1. To assign a metric to a
network connection:

a. Open the Network Connections folder.
b. Right click the desired connection.
c. Click Properties | Internet Protocol (TCP/IP).
d. Click Properties | Advanced.
e. Un-check "Automatic metric".
f. Enter a number between 1 and 9999 for the "Interface metric".


You are right about there being two degault gateways. What went with
changing the metrics. So far things look to be working better.

Thank you,

TC
 
Back
Top