Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Addition default Gateways... What's the point?

Posted on 2004-09-16
5
Medium Priority
?
323 Views
Last Modified: 2010-08-05
Like the tile says "What's the point?"  In Windows XP you can configure a NIC to have multiple default gateways.  And it so happens that my network has 2.  But it doesn't seem to matter how many gateways you add, because it will always use the first one.  Here is an example:

"Computer A" is using default gateway "192.168.123.1"
"Computer B" is using default gateway "192.168.123.2"
"Webserver" is using default gateway "192.168.123.1" and hosts www.fakewebsite.com (this is obviously fake)
"Ftpserver" is using default gateway "192.168.123.2" and hosts ftp.fakeftpsite.com

Computer B goes to http://www.fakewebsite.com it works fine.
Computer A goes to http://www.fakewebsite.com it doesnt't work (and I don't expect it to)
Computer A goes to ftp://ftp.fakeftpsite.com it works fine.
Computer B goes to ftp://ftp.fakeftpsite.com it doesnt't work (again, I don't expect it to)

I thought if I added the other gateways to each Computer's NIC it would work around this problem of client and server being on the same default gateway.

WRONG!!!!

So... what is it used for?
0
Comment
Question by:swamprattakate
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 15

Accepted Solution

by:
scampgb earned 500 total points
ID: 12077985
Hi swamprattakate,

I'm a bit confused about the testing you're doing.
In the example above, it looks like all of the machines are on the same subnet (assuming netmask 255.255.255.0).
In this case, the default gateway wouldn't get used at all.

It would help if you posted the IP addresses of the actual machines, then we can look at what's really happening.

Anyway, in answer to your question "what's the point".
The PC will try and use the default gateway to get to any address that isn't on it's own subnet.
If for some reason it can't contact the first default gateway (the router died for example), then it'll try the second one instead.

Does that help?
0
 

Author Comment

by:swamprattakate
ID: 12078816
OK I should add more info.
There are 2 DSL routers on the network, and they both are using NAT.

The LAN address of "Router 1"  is 192.168.123.1 and the WAN address is 64.41.229.110
The LAN address of "Router 2"  is 192.168.123.1 and the WAN address is 64.41.223.242

So when Computer B requests http://www.fakewebsite.com it works fine.  Because it connects to the internet thru Router 2, the url resolves to 64.41.229.110, Router 1 using NAT routes the request to Webserver.
But when Computer A requests http://www.fakewebsite.com it works fine.  Because it connects to the internet thru Router 1,  "the page cannot be displayed"

So to solve my problem, maybe Multiple Gateways is not the solution, because, as you said, it is for when it cannot connect to the first Router.  Is there a way to make the url resolve to the local IP address of the server without changing all of the HOST files on each computer?
0
 
LVL 79

Assisted Solution

by:lrmoore
lrmoore earned 500 total points
ID: 12079539
>But it doesn't seem to matter how many gateways you add, because it will always use the first one
That is expected behavior. Only the one with the lowest metric will be used. If that one happens to go unreachable, then the next lower metric will take over. This is called "Dead Gateway Detection"
That's the point of having multiple default gateways, as explained by scampgo

You can, however, add static routes to the hosts. For example:

The LAN address of "Router 1"  is 192.168.123.1
The LAN address of "Router 2"  is 192.168.123.1 <== assume this is a typo?
Can we assume that www.fakewebsite.com = 64.41.229.110 ?

CompA:  c:\> route add 64.41.229.110 mask 255.255.255.255 192.168.123.2  <--Router 2

>Is there a way to make the url resolve to the local IP address of the server without changing all of the HOST files on each computer?
Yes, setup your own DNS server on each LAN.

You might try adding a route on Router1:
LAN IP: 64.41.223.242
MASK: 255.255.255.255
Gateway: 192.168.123.2  <-- router 2
Metric: 1

AND on Router2:
  LAN IP: 64.41.229.110
  MASK: 255.255.255.255
  Gatway: 192.168.123.1 <-- router 1
  Metric: 1

Or, maybe I'm just totally confused in that you have two separate and distinct networks, both of which are 192.168.123, and 192.168.123.1 is their respective gateway to their respective DSL connection?

Maybe if I understood how you are setup better...
www.fakewebsite.com 
  Webserver real IP address = 192.168.123.??
  Webserver Default gateway = 192.168.123.1 <-- router 1
  Webserver DNS entry = 64.41.229.110

ftp.fakewebsite.com
  FTP server real IP addres = 192.168.123.??
  FTP server default gateway = 192.168.123.2 <-- router 2?
  FTP Server DNS entry = 64.41.223.242 ??
 
And, your goal is for users on LAN A to get to both WWW and FTP.fakesite.com
AND for users on LANB to get to both WWW and FTP.fakesite.com 
?
0
 

Author Comment

by:swamprattakate
ID: 12085053
Since my question "What's the point of multiple gateways?" has morphed into a much larger problem involving DNS and Subnetting, I am going to split the points because technically "Dead Gateway Detection" was the answer to the original question.  But, I got a lot more information about my real problem, and the solution came with changinge the settings on our DNS server.  So thanks.
0
 
LVL 15

Expert Comment

by:scampgb
ID: 12085354
swamprattakate:  Thanks for the "A".  Glad I could help and that you got it sorted in the end :-)



0

Featured Post

Supports up to 4K resolution!

The VS192 2-Port 4K DisplayPort Splitter is perfect for anyone who needs to send one source of DisplayPort high definition video to two or four DisplayPort displays. The VS192 can split and also expand DisplayPort audio/video signal on two or four DisplayPort monitors.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

We recently endured a series of broadcast storms that caused our ISP to shut us down for brief periods of time. After going through a multitude of tests, we determined that the issue was related to Intel NIC drivers on some new HP desktop computers …
An article on effective troubleshooting
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

715 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question