Unsolved

This post is more than 5 years old

1 Rookie

 • 

6 Posts

10109

January 22nd, 2008 06:00

Multiple Default Gateways

We have a PE2950 with 2 NICs. This is a member server, running SQL Server/Analysis Services 2005.
 
The NICs are attached to seperate networks. One being our internal LAN, the other is to access our WAN. The NIC attached to the WAN has a default gateway of the router used to access other sites within the WAN.
 
Users are going to be accessing the server via the LAN network card for which there is no default gateway specified. I believe this is the reason why we cannot connect direct to the server remotely.
 
The 192.1.100.x LAN NIC has no default gateway and the 150.7.x.x WAN network has a default gateway specified.
 
In theory I am looking to achieve the following:-
NIC1 192.1.100.x network, default gateway 192.1.100.254
NIC2 150.7.x.x network,default gateway 150.7.99.254.
 
How can we have a server with 2 NICS and each one having a default gateway belonging to different networks?
 
On trying to add a gateway to the LAN network card, I get the following msg "Multiple default gateways are intended to provide redundancy for a single network. They will not function properly when the gateways are on two separate, disjoint network."
 
Is there a way that this type of setup can be achieved and is there anything that I need to be aware in terms of potential issues/complications?
 
Would be grateful for any advice/guidance or alternative solutions.

667 Posts

January 23rd, 2008 10:00

Here's my attempt at routing 101:
 
If you open a command window, you can type
 
   C:\> route print
 
This shows the routing table for all networks attached to the machine.
 
What you want is the users on the 192.1.100.x LAN to enter and exit the LAN NIC.  This NIC should see an entry
 
Destination          Netmask                Gateway                        Interface
192.1.100.0         255.255.255.0               
 
This requires all users of the server be on the 192.1.100.x subnet.  Are they?  If you have other subnets in the network, you'll have to setup routing for those manually. Enter the command:
 
    C:\> route ?
 
to see all the switches and options for the route command.  Assuming there is another subnet of 10.200.7.x (with a mask of 255.255.255.0), you would enter the command:
 
    C:\>route -p add 10.200.7.0 mask 255.255.255.0
 
Only the external interface should have the default route 0.0.0.0.  This routes all addresses not already defined out to the Internet.  You do want access to the Internet, right?
 
Also, you're not directly connecting the server to the Internet, right?  You do have a firewall with all the ports closed except only what's necessary, right?  Connecting a database server directly to the Internet is really risky.
 
Lastly,
 
Make sure TCP/IP is enabled in SQL Server.  If you're using the Express Edition, it comes with TCP/IP disabled by default.
 

21 Posts

January 23rd, 2008 21:00

You don't want multiple default gateways.  You need to declare the routes and gateways.  Default gateways are what your machine uses when the route isn't known. 
 
ie: route -p ADD 157.7.0.0 MASK 255.255.0.0 157.7.99.254
 
Also, make sure you do this on the other side as well, as the traffic needs to know how to get back.


Message Edited by scheesman on 01-23-2008 06:26 PM

Top