Windows XP Community - XPHeads



Registry Mechanic - Free Scan Now

Modifying default routes. Use route.exe?

microsoft.public.windowsxp.network_web


Reply
  #1 (permalink)  
Old 01-17-2008, 10:16 AM
James Egan
 
Posts: n/a
Modifying default routes. Use route.exe?

Hello,

Does anyone know if it's possible to modify the metrics on two default
gateways from a command line or something that can be executed
automatically without requiring a user to make advanced manual
alterations to the tcp/ip network settings?

Currently on startup (having set the metrics manually), the routing
table looks like this where the second default gateway is only used if
the first one is dead. This works okay.

================================================== =========================
Active Routes:
Network Destination Netmask Gateway Interface
Metric
0.0.0.0 0.0.0.0 192.168.7.1 192.168.7.50
1
0.0.0.0 0.0.0.0 192.168.7.2 192.168.7.50
20
127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1
1
192.168.7.0 255.255.255.0 192.168.7.50 192.168.7.50
25
192.168.7.50 255.255.255.255 127.0.0.1 127.0.0.1
25
192.168.7.255 255.255.255.255 192.168.7.50 192.168.7.50
25
224.0.0.0 240.0.0.0 192.168.7.50 192.168.7.50
25
255.255.255.255 255.255.255.255 192.168.7.50 192.168.7.50
1
Default Gateway: 192.168.7.1
================================================== =========================
Persistent Routes:
None

I would like to occasionally switch the metrics around on these
gateways so that 192.168.7.2 is used first but I don't know how to do
it automatically.

Whatever I do with the route command, I always end up with a single
default gateway.

Perhaps there is something other than route.exe I can use?


Jim.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 01-18-2008, 06:09 AM
Steve Winograd
 
Posts: n/a
Re: Modifying default routes. Use route.exe?
On Thu, 17 Jan 2008 10:16:38 +0000, James Egan <jegan@jegan.com>
wrote:
>Hello,
>
>Does anyone know if it's possible to modify the metrics on two default
>gateways from a command line or something that can be executed
>automatically without requiring a user to make advanced manual
>alterations to the tcp/ip network settings?
>
>Currently on startup (having set the metrics manually), the routing
>table looks like this where the second default gateway is only used if
>the first one is dead. This works okay.
>
>================================================= ==========================
>Active Routes:
>Network Destination Netmask Gateway Interface
>Metric
> 0.0.0.0 0.0.0.0 192.168.7.1 192.168.7.50 1
> 0.0.0.0 0.0.0.0 192.168.7.2 192.168.7.50 20
> 127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1
> 192.168.7.0 255.255.255.0 192.168.7.50 192.168.7.50 25
> 192.168.7.50 255.255.255.255 127.0.0.1 127.0.0.1 25
> 192.168.7.255 255.255.255.255 192.168.7.50 192.168.7.50 25
> 224.0.0.0 240.0.0.0 192.168.7.50 192.168.7.50 25
> 255.255.255.255 255.255.255.255 192.168.7.50 192.168.7.50 1
>Default Gateway: 192.168.7.1
>================================================= ==========================
>Persistent Routes:
> None
>
>I would like to occasionally switch the metrics around on these
>gateways so that 192.168.7.2 is used first but I don't know how to do
>it automatically.
>
>Whatever I do with the route command, I always end up with a single
>default gateway.
>
>Perhaps there is something other than route.exe I can use?
>
>
>Jim.


Delete the default routes, then create routes with the desired
metrics. Here are two ways to do it:

route delete 0.0.0.0 mask 0.0.0.0
route add 0.0.0.0 mask 0.0.0.0 192.168.7.1 metric 1
route add 0.0.0.0 mask 0.0.0.0 192.168.7.2 metric 20

or:

route change 0.0.0.0 mask 0.0.0.0 192.168.7.1 metric 1
route add 0.0.0.0 mask 0.0.0.0 192.168.7.2 metric 20
--
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
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 01-18-2008, 11:00 AM
James Egan
 
Posts: n/a
Re: Modifying default routes. Use route.exe?

On Thu, 17 Jan 2008 23:09:43 -0700, Steve Winograd
<bc070521m@comcast.net> wrote:

>Delete the default routes, then create routes with the desired
>metrics. Here are two ways to do it:
>
>route delete 0.0.0.0 mask 0.0.0.0
>route add 0.0.0.0 mask 0.0.0.0 192.168.7.1 metric 1
>route add 0.0.0.0 mask 0.0.0.0 192.168.7.2 metric 20
>
>or:
>
>route change 0.0.0.0 mask 0.0.0.0 192.168.7.1 metric 1
>route add 0.0.0.0 mask 0.0.0.0 192.168.7.2 metric 20



Steve,

This is what I thought I was doing but obviously wasn't because it
works.

Many thanks.



Jim.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 01-18-2008, 04:36 PM
Steve Winograd
 
Posts: n/a
Re: Modifying default routes. Use route.exe?
On Fri, 18 Jan 2008 11:00:20 +0000, James Egan <jegan@jegan.com>
wrote:
>On Thu, 17 Jan 2008 23:09:43 -0700, Steve Winograd
><bc070521m@comcast.net> wrote:
>
>>Delete the default routes, then create routes with the desired
>>metrics. Here are two ways to do it:
>>
>>route delete 0.0.0.0 mask 0.0.0.0
>>route add 0.0.0.0 mask 0.0.0.0 192.168.7.1 metric 1
>>route add 0.0.0.0 mask 0.0.0.0 192.168.7.2 metric 20
>>
>>or:
>>
>>route change 0.0.0.0 mask 0.0.0.0 192.168.7.1 metric 1
>>route add 0.0.0.0 mask 0.0.0.0 192.168.7.2 metric 20

>
>Steve,
>
>This is what I thought I was doing but obviously wasn't because it
>works.
>
>Many thanks.
>
>Jim.


You're welcome, Jim. :-)
--
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
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
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

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



All times are GMT. The time now is 07:51 PM.


Registry Mechanic - Free Scan Now
Driver Scanner 2009 - Free Scan Now




Design by Vjacheslav Trushkin for phpBBStyles.com.
Powered by vBulletin® Version 3.6.7
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.1.0

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74