Adding a route question

G

Guest

Hi,

I am in the process of setting up a routed network. One network is
192.168.1.0/24 and the other is 192.168.2.0/26. I have configured a windows
2000 router with 2 network cards to each represent the networks. However
when I try to use the “route add –p†command to add a persistent route to the
networks I get an interface error message. Can someone show me what the
command would be if my network cards are configured the following way?

ETHERNET ADAPTER 1
IP address 192.168.1.1
Subnet mask 255.255.255.0
Gateway 192.168.2.1

ETHERNET ADAPTER 2
IP address 192.168.2.1
Subnet mask 255.255.255.192
Gateway 192.168.1.1

Regards
Sam
 
R

Robert L [MS-MVP]

if you have enabled the IP routing, it should create router for you and you don't need to do it. posting the routing table will help. or visit this page, http://www.chicagotech.net/routing.htm

Don't send e-mail or reply to me except you need consulting services. Posting on MS newsgroup will benefit all readers and you may get more help.

Bob Lin, MS-MVP, MCSE & CNE
How to Setup Windows, Network, Remote Access on http://www.HowToNetworking.com
Networking, Internet, Routing, VPN Troubleshooting on http://www.ChicagoTech.net
This posting is provided "AS IS" with no warranties.
I recommend Brinkster for web hosting!

Hi,

I am in the process of setting up a routed network. One network is
192.168.1.0/24 and the other is 192.168.2.0/26. I have configured a windows
2000 router with 2 network cards to each represent the networks. However
when I try to use the “route add –p†command to add a persistent route to the
networks I get an interface error message. Can someone show me what the
command would be if my network cards are configured the following way?

ETHERNET ADAPTER 1
IP address 192.168.1.1
Subnet mask 255.255.255.0
Gateway 192.168.2.1

ETHERNET ADAPTER 2
IP address 192.168.2.1
Subnet mask 255.255.255.192
Gateway 192.168.1.1

Regards
Sam
 
G

Guest

Hi Sam,
ETHERNET ADAPTER 1
IP address 192.168.1.1
Subnet mask 255.255.255.0
Gateway 192.168.2.1

ETHERNET ADAPTER 2
IP address 192.168.2.1
Subnet mask 255.255.255.192
Gateway 192.168.1.1

your ip address & gateway address is not match! pls chek?

Regards,

John
 
H

Herb Martin

Sam said:
Hi,

I am in the process of setting up a routed network. One network is
192.168.1.0/24 and the other is 192.168.2.0/26.

The above is legal, but out of curiousity did you mean
to have different masks?
I have configured a windows
2000 router with 2 network cards to each represent the networks. However
when I try to use the "route add -p" command to add a persistent route to the
networks I get an interface error message. Can someone show me what the
command would be if my network cards are configured the following way?

"Windows 2000 router" - may we presume you are using
RRAS?

It is MUCH better (i.e., it works) if you add RRAS routes
through the RRAS MMC or through NetSh.exe.

The Route Add command should probably be left strictly
for ordinary Windows machine (workstations etc) without
RRAS.

With ONE router you don't need any static routers (actually
with two routers you don't either.) With one router it is
connected to EVERYTHING so it already knows about
everything from the default building of the routing table.

With two routers they can point to each other as "default
gateway" so no static routes need to be manually ADDED.
(The default gateway settings inherently create those static
routes.)

Now, be careful, since most people connect to the Internet,
and the ISP has a router which COUNTS in our totol, so
with one internal router and the Internet we don't need any
manual routes on that internal router since it just uses the
ISP as "default gateway".

Only "middle routers" (my term) need added routes to point
to the smaller networks of the routers it is in contact with.
Why "smaller networks"? Well, because it will use the
router connected to the largest (or really most diverse)
networks as it's default gateway (usually that's the ISP,
or the upstream router that eventually leads to the ISP and
the Internet (or maybe to "headquarters" if we are a branch
office.

So assuming you have ONE internal router, you just set its
default gateway to the ISP's router.

Assuming your have the router below AND another router
with say "DSL upstream" (to the ISP) and 192.168.1.2 on the
INTERNAL side you would route from this "middle router"
to the 192.168.2.0 network this way:

route add 192.168.2.0 mask 255.255.255.252 192.168.2.1

(Although that mask still looks to be a typo.)
ETHERNET ADAPTER 1
IP address 192.168.1.1
Subnet mask 255.255.255.0
Gateway 192.168.2.1

ON THE OTHER router(s), to reach this router
you
 
H

Herb Martin

Sam said:
Hi,

I am in the process of setting up a routed network. One network is
192.168.1.0/24 and the other is 192.168.2.0/26.

The above is legal, but out of curiosity did you mean
to have different masks?
I have configured a windows
2000 router with 2 network cards to each represent the networks. However
when I try to use the "route add -p" command to add a persistent route to the
networks I get an interface error message. Can someone show me what the
command would be if my network cards are configured the following way?

"Windows 2000 router" - may we presume you are using
RRAS?

It is MUCH better (i.e., it works) if you add RRAS routes
through the RRAS MMC or through NetSh.exe.

The Route Add command should probably be left strictly
for ordinary Windows machine (workstations etc) without
RRAS.

With ONE router you don't need any static routers (actually
with two routers you don't either.) With one router it is
connected to EVERYTHING so it already knows about
everything from the default building of the routing table.

With two routers they can point to each other as "default
gateway" so no static routes need to be manually ADDED.
(The default gateway settings inherently create those static
routes.)

Now, be careful, since most people connect to the Internet,
and the ISP has a router which COUNTS in our total, so
with one internal router and the Internet we don't need any
manual routes on that internal router since it just uses the
ISP as "default gateway".

Only "middle routers" (my term) need added routes to point
to the smaller networks of the routers it is in contact with.
Why "smaller networks"? Well, because it will use the
router connected to the largest (or really most diverse)
networks as it's default gateway (usually that's the ISP,
or the upstream router that eventually leads to the ISP and
the Internet (or maybe to "headquarters" if we are a branch
office.

So assuming you have ONE internal router, you just set its
default gateway to the ISP's router.

Assuming your have the router below AND another router
with say "DSL upstream" (to the ISP) and 192.168.1.2 on the
INTERNAL side you would route from this "middle router"
to the 192.168.2.0 network this way:

route add -p 192.168.2.0 mask 255.255.255.252 192.168.2.1

(Although that mask still looks to be a typo.)

And remember, if you are using RRAS it is best to enter this
in the RRAS console or using NetSH (not "route add".)
ETHERNET ADAPTER 1
IP address 192.168.1.1
Subnet mask 255.255.255.0
Gateway 192.168.2.1

ON THE OTHER router(s), to reach this router
you
 
G

Guest

Hi Herb,

Thanks for replying and the answer is: Yes I am using RRAS.

I will try what you suggested.

Regards,
Sam
 
G

Guest

Hi Herb,

Do I have my network cards gateways configured correctly?

ETHERNET ADAPTER 1
IP address 192.168.1.1
Subnet mask 255.255.255.0
Gateway 192.168.2.1

ETHERNET ADAPTER 2
IP address 192.168.2.1
Subnet mask 255.255.255.192
Gateway 192.168.1.1

Or should it be

ETHERNET ADAPTER 1
IP address 192.168.1.1
Subnet mask 255.255.255.0
Gateway 192.168.1.1

ETHERNET ADAPTER 2
IP address 192.168.2.1
Subnet mask 255.255.255.192
Gateway 192.168.2.1
 
H

Herb Martin

Sam said:
Hi Herb,

Do I have my network cards gateways configured correctly?

ETHERNET ADAPTER 1
IP address 192.168.1.1
Subnet mask 255.255.255.0
Gateway 192.168.2.1
ETHERNET ADAPTER 2
IP address 192.168.2.1
Subnet mask 255.255.255.192
Gateway 192.168.1.1

Or should it be
ETHERNET ADAPTER 1
IP address 192.168.1.1
Subnet mask 255.255.255.0
Gateway 192.168.1.1
ETHERNET ADAPTER 2
IP address 192.168.2.1
Subnet mask 255.255.255.192
Gateway 192.168.2.1

There is no point in having a machine
point to it's own adapter for Default
Gateway. Both SETS are wrong.

The default gateway is the "router of
last resort" -- that is, they place where
a machine (or even a router) sends traffic
for which it does NOT know the correct
(or a better) destination or route.

This means that for routers the Default
Gateway is the near side of the adjacent
router (directly connected to one its NICs)
that can handle most or all traffic.


How many routers do you have total?

If you don't have more than one internally
then this router should be set to the ISPs
router for "default gateway"; if you have two
then the one that is NOT connected to the
ISP must use the one connected to the ISP
as default.

IF you have more than 2 we have to talk about
the placement and connections.

For a single router (not connected to the Internet)
in the world by itself, then the default gateway
setting is meaningless.

For a router between two (other) routers the
default gateway goes to the router connected to
the "large" group of networks (probably the
Internet) and the manual route goes to the "edge"
router or the router with the smaller number
of networks.
 
H

Herb Martin

Sam said:
Hi Herb,

Yes I do mean to have different mask.

Why?

It's not wrong, but by your other entries you
have some basic misunderstandings of routing
so your might be expecting or trying something
that isn't going to work here.

Read my other response this thread and call me
if you need more help.

Phone is on my web site: www.LearnQuick.Com
 
P

Phillip Windell

Why screw around with static routes? You have *no* "routes". You have one
router with only two Segments that are both "directly connected",...there
are *no* routes. You don't use "routes" for networks that are "directly
connected",...the router *already* knows where they are.

At a command prompt type:

"route /f"

Then reboot,...leave it alone.
 
G

Guest

Hi,

Let me explain myself better. The router is a windows 2000 machine with 2
network cards and RRAS is setup to do the routing. The 192.168.1.1 is
connected to one network and the 192.168.2.1 is connected to the other. So
from what you are telling me I do not need to setup a default gateway on
either of these cards? It is self-understanding?

This is a new structure I am testing, and has not gone into production.

Also my Internet connection is through a firewall 192.168.1.2. When the
default gateway is change on client workstation from 192.168.1.2 to
192.168.1.1 (on that network) I cannot access the Internet, but I can ping
the new network. If I change it back I can access the Internet but not the
192.168.2.0 network. The same thing goes for the 192.168.2.0 network.

What I would like to know is: What would I have to do at the windows 2000
router machine to be able to have both networks access the internet through
the firewall’s IP address?


Best regards,
Sam


Phillip Windell said:
Why screw around with static routes? You have *no* "routes". You have one
router with only two Segments that are both "directly connected",...there
are *no* routes. You don't use "routes" for networks that are "directly
connected",...the router *already* knows where they are.

At a command prompt type:

"route /f"

Then reboot,...leave it alone.

--

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


Sam said:
Hi,

I am in the process of setting up a routed network. One network is
192.168.1.0/24 and the other is 192.168.2.0/26. I have configured a windows
2000 router with 2 network cards to each represent the networks. However
when I try to use the "route add -p" command to add a persistent route to the
networks I get an interface error message. Can someone show me what the
command would be if my network cards are configured the following way?

ETHERNET ADAPTER 1
IP address 192.168.1.1
Subnet mask 255.255.255.0
Gateway 192.168.2.1

ETHERNET ADAPTER 2
IP address 192.168.2.1
Subnet mask 255.255.255.192
Gateway 192.168.1.1

Regards
Sam
 
P

Phillip Windell

Sam said:
Let me explain myself better. The router is a windows 2000 machine with 2
network cards and RRAS is setup to do the routing. The 192.168.1.1 is
connected to one network and the 192.168.2.1 is connected to the other. So
from what you are telling me I do not need to setup a default gateway on
either of these cards? It is self-understanding?

No. I'm telling you that you don't use any static routes (route add -p). It
already knows where the two network segments are because they are connected
directly to it. You only use one Default Gateway,...it goes on the Nic that
leads toward the Internet,..the actual DFG IP# will most likely be the
Internet NAT Device.

All machines on the LAN use the "LAN router" as their DFG,...it is up to the
LAN router to know what to do with it from there.
 
G

Guest

Hi,

Okay, I see what you mean, and I made some changes; however, I can connect
to the Internet only from one segment. The 192.168.1.0 referred to as Segment
A.

The Segment A client has a default gateway of 192.168.1.1, and that Nic has
a default gateway of 192.168.1.2, and everything on that segment connects to
the internet, and the 192.168.2.0 network referred to as segment B.

On segment B I can ping devices on segment A, but I cannot connect to the
Internet. What could be wrong?

Best regards,
Sam
 
H

Herb Martin

Sam said:
Hi,

Okay, I see what you mean, and I made some changes; however, I can connect
to the Internet only from one segment. The 192.168.1.0 referred to as Segment
A.

List EVERY router you have -- including anything
connected to your cable-modem/DSL/other internet
connection.
The Segment A client has a default gateway of 192.168.1.1, and that Nic has
a default gateway of 192.168.1.2, and everything on that segment connects to
the internet, and the 192.168.2.0 network referred to as segment B.

On segment B I can ping devices on segment A, but I cannot connect to the
Internet. What could be wrong?

You have ANOTHER router -- I have explained to you
several time that the "middle" router is going to be where
the "static routes are needed."

The "edge" routers will just use the upstream router as
their Default Gateway.

You have been focusing on a single router. Single routers
don't need static routes -- they know everything (there is
to know.)

Until you tell us about the OTHER routers we cannot give
you the answer (but you could figure it out based on my
other messages.)

And yes, you must have another router since all of your
addresses are private ones, there must be one that has
private AND public addresses (unless you ISP does that
which is unlikely.)

How do you connect to the Internet? Which machine does
that...?
 
G

Guest

Hi,

I connect to the internet through a firewall. The firewall has a private
nic and a public the private nic is 192.168.1.2, and the public is
200.xxx.xxx.xxx. The router that I have created is the middle router?

Regards,
Sam
 
H

Herb Martin

Sam said:
Hi,

I connect to the internet through a firewall. The firewall has a private
nic and a public the private nic is 192.168.1.2, and the public is
200.xxx.xxx.xxx. The router that I have created is the middle router?

It is on this firewall you will need to add the
static route (if it supports such.)

It will need to add (something like):

route add 192.168.2.0 mask 255.255.255.192.0 192.168.1.1

Where the 192.168.1.1 is your router we have been discussing.

And where it (192.168.1.1) would use 192.168.1.1 as it's
default gateway.

This is the "middle router". The one between your INTERNAL
(to your LAN) router, and the ISP.
 
R

Roland Hall

in message
: I connect to the internet through a firewall. The firewall has a private
: nic and a public the private nic is 192.168.1.2, and the public is
: 200.xxx.xxx.xxx. The router that I have created is the middle router?

Sam...

It appears you have this:

FW: WAN: 200.x.x.x
FW: LAN: 192.168.1.2

It connects to a hub/switch.

RRAS NIC1: 192.168.1.1
RRAS NIC2: 192.168.2.1

RRAS NIC1 and FW LAN both connect to same hub/switch.
RRAS NIC2 connects to different hub/switch.

FW needs default gateway to WAN side of ISP's router. 200.x.x.x
FW needs static route to 192.168.2.0 using interface 192.168.1.1

RRAS needs DFG to 192.168.1.2
All systems on 192.168.1.0 network need DFG to 192.168.1.2
All systems on 192.168.2.0 network need DFG to 192.168.2.1

You don't want to point the DFG on 192.168.1.0 network to 192.168.1.1 to get
to the 192.168.2.0 network. The systems on the 192.168.1.0 network will
default to the edge router (FW) and the router (FW) will tell them how to
get there (via 192.168.1.1). All systems looking for systems on 192.168.1.0
will be directed there from the middle router. If they're trying to get to
the Internet, then the middle router will route them to its default gateway
which is 192.168.1.2 (FW).

The basic concept is static route to routes you know and default to routes
you don't know. The only part missing to this puzzle is the ISP setting a
route to the public addressing they gave you (200.x.x.x).

--
Roland Hall
/* This information is distributed in the hope that it will be useful, but
without any warranty; without even the implied warranty of merchantability
or fitness for a particular purpose. */
Online Support for IT Professionals -
http://support.microsoft.com/servicedesks/technet/default.asp?fr=0&sd=tech
How-to: Windows 2000 DNS:
http://support.microsoft.com/default.aspx?scid=kb;EN-US;308201
FAQ W2K/2K3 DNS:
http://support.microsoft.com/default.aspx?scid=kb;EN-US;291382
 
P

Phillip Windell

Herb Martin said:
You have ANOTHER router -- I have explained to you
several time that the "middle" router is going to be where
the "static routes are needed."

The "edge" routers will just use the upstream router as
their Default Gateway.

I forgot to add that the NAT Device will require a Static Route for the LAN
Segment that is on the opposite side of the LAN Router from where it sits.
This is the only Static Route in the entire thing that I can think of.

I don't think the LAN Router (middle router) would have any static routes
because everything is "directly" connected as far as it is concerned,...i
would only have the Default Gateway.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top