static routing and route-map

static routing and route-map

Post by henr » Wed, 22 Jan 2003 15:10:21



I am confused with static routing and route-map with set ip next-hop,can
anybody help me?
router A-(10.1.2.3)-------switch---------(e0)-router B---(s0)
router C-(10.1.2.2)----------+

if router B has following config:
ip route 192.168.1.0 255.255.0.0 Ethernet0 10.1.2.3
ip route 192.168.1.0 255.255.0.0 Ethernet0 10.1.2.2 50
if router A fail,does route change to router C?How does it know this? router
A doesn't response to arp which router B send? or anything. If router B
doesn't know this(router A fail).How should the router B do?
if router A and C both fail,And router B has no route to 192.168.1.0 and no
bit bucket. but it has packet which destination is 192.168.1.0. What's the
action the router B will do? Drop or hold or anything else?

if router B has following config:
interface Serial0
ip policy route-map Albert
!
access-list 1 permit 172.16.0.0 0.0.255.255
access-list 2 permit 172.17.0.0 0.0.255.255
!
route-map Albert permit 10
match ip address 1
set ip next-hop 10.1.2.3
!
route-map Albert permit 20
match ip address 2
set ip next-hop 10.1.2.2

If router A fail,the packet which source is 172.16.0.0/16 should drop by
router B or send to LAN by router B?
If router B know this(router A fail),can router B put the packet to the
normal routing process(like dynamic routing)

thanks! any comment is appreciated.

 
 
 

static routing and route-map

Post by Thomas Kubor » Wed, 22 Jan 2003 18:51:53


see in-line


Quote:> I am confused with static routing and route-map with set ip next-hop,can
> anybody help me?
> router A-(10.1.2.3)-------switch---------(e0)-router B---(s0)
> router C-(10.1.2.2)----------+

> if router B has following config:
> ip route 192.168.1.0 255.255.0.0 Ethernet0 10.1.2.3
> ip route 192.168.1.0 255.255.0.0 Ethernet0 10.1.2.2 50
> if router A fail,does route change to router C?

No. Router B has no way of knowing that router A failed. Therefore, the
static route to A will stay in the routing table.
You could solve this by :
1/ dynamic routing protocol : when a router fails, hellos will stop & the
route will change
2/ static route to a connected interface : ip route 192.168.1.0 255.255.0.0
Ethernet0

Quote:> How does it know this?

I dont

Quote:> router A doesn't response to arp which router B send?

router A won't respond to ARP request but router B won't do anything

Quote:>or anything. If router B doesn't know this(router A fail).How should the

router B do?

Router B won't do anything

Quote:> if router A and C both fail,And router B has no route to 192.168.1.0 and
no
> bit bucket. but it has packet which destination is 192.168.1.0. What's the
> action the router B will do? Drop or hold or anything else?

DROP

Quote:> if router B has following config:
> interface Serial0
> ip policy route-map Albert
> !
> access-list 1 permit 172.16.0.0 0.0.255.255
> access-list 2 permit 172.17.0.0 0.0.255.255
> !
> route-map Albert permit 10
> match ip address 1
> set ip next-hop 10.1.2.3
> !
> route-map Albert permit 20
> match ip address 2
> set ip next-hop 10.1.2.2

> If router A fail,the packet which source is 172.16.0.0/16 should drop by
> router B or send to LAN by router B?
> If router B know this(router A fail),can router B put the packet to the
> normal routing process(like dynamic routing)

> thanks! any comment is appreciated.

This won't solve anything because you'll still have a route to 10.1.2.3 even
if Router A has failed.
The reason why you'll still have a route to 10.1.2.3 is because the Ethernet
0 interface on router B is up.
You could either use dynamic routing protocol or a static route to a
connected interface (I believe)

Thomas

 
 
 

static routing and route-map

Post by Mathias Gaertne » Wed, 22 Jan 2003 19:49:29


Hi,

Quote:

> No. Router B has no way of knowing that router A failed. Therefore, the
> static route to A will stay in the routing table.
> You could solve this by :
> 1/ dynamic routing protocol : when a router fails, hellos will stop & the
> route will change

That's the only way of doing that

Quote:> 2/ static route to a connected interface : ip route 192.168.1.0 255.255.0.0
> Ethernet0

Nope, the route would disappear only if that interface is going down,
which, in this case would happen if the switch is rebooting or otherwise
failing.

Quote:

>>bit bucket. but it has packet which destination is 192.168.1.0. What's the
>>action the router B will do? Drop or hold or anything else?

> DROP

To be precise, the route to router A still exists in the fib. If router
B happens to have the arp entry in the arp cache it would just send the
packets to the switch.
If there's no arp-entry it would send arp-requests as broadcasts onto
the ethernet. During that time it will queue all packets destined to
192.168.1.0 and will start dropping packets according the qos-policy
attached (in this case: will drop tail of queue).

Quote:

>>if router B has following config:
>>interface Serial0
>>ip policy route-map Albert
>>!
>>access-list 1 permit 172.16.0.0 0.0.255.255
>>access-list 2 permit 172.17.0.0 0.0.255.255
>>!
>>route-map Albert permit 10
>>match ip address 1
>>set ip next-hop 10.1.2.3
>>!
>>route-map Albert permit 20
>>match ip address 2
>>set ip next-hop 10.1.2.2

>>If router A fail,the packet which source is 172.16.0.0/16 should drop by
>>router B or send to LAN by router B?
>>If router B know this(router A fail),can router B put the packet to the
>>normal routing process(like dynamic routing)

If we assume that router b looses it's route to 10.1.2.3 then AFAIK the
route-map still would work and would try to send the packets to 10.1.2.3.

Mathias

 
 
 

static routing and route-map

Post by Thomas Kubor » Wed, 22 Jan 2003 20:11:49


Quote:> > 2/ static route to a connected interface : ip route 192.168.1.0
255.255.0.0
> > Ethernet0
> Nope, the route would disappear only if that interface is going down,
> which, in this case would happen if the switch is rebooting or otherwise
> failing.

Right but I'm not talking about a switch failure ;-)

The discussion is over the failure of router A.
When using a static route to a connected interface, the router will ARP for
the destination IP address in the IP packets.

This would only require one static route, not necessary to have a 2nd one
with a higher AD.

When router A fails, router B will (when its ARP entry ages out) ARP for the
destination IP address of the IP packets.
If router C is configured with proxy-ARP (Cisco default), it will reply &
connectivity will be maintained.

Requirements :
1/ lower arp timer
2/ proxy arp support

I'm not saying this is a good solution, only that it will "work"

Mr T

 
 
 

static routing and route-map

Post by henr » Thu, 23 Jan 2003 10:26:59


thanks all. I think I understand it.
thanks again!
 
 
 

static routing and route-map

Post by henr » Thu, 23 Jan 2003 11:04:28


I have another question.
If router B loose route to 10.1.2.3,can router B put the packet to the
normal routing process or drop it?

Quote:> > if router B has following config:
> > interface Serial0
> > ip policy route-map Albert
> > !
> > access-list 1 permit 172.16.0.0 0.0.255.255
> > access-list 2 permit 172.17.0.0 0.0.255.255
> > !
> > route-map Albert permit 10
> > match ip address 1
> > set ip next-hop 10.1.2.3
> > !
> > route-map Albert permit 20
> > match ip address 2
> > set ip next-hop 10.1.2.2

> > If router A fail,the packet which source is 172.16.0.0/16 should drop by
> > router B or send to LAN by router B?
> > If router B know this(router A fail),can router B put the packet to the
> > normal routing process(like dynamic routing)

> > thanks! any comment is appreciated.

> This won't solve anything because you'll still have a route to 10.1.2.3
even
> if Router A has failed.
> The reason why you'll still have a route to 10.1.2.3 is because the
Ethernet
> 0 interface on router B is up.
> You could either use dynamic routing protocol or a static route to a
> connected interface (I believe)

> Thomas

 
 
 

static routing and route-map

Post by Thomas Kubor » Thu, 23 Jan 2003 19:07:01


Normal routing I believe: less specific path or even a default path

Mr T


Quote:> I have another question.
> If router B loose route to 10.1.2.3,can router B put the packet to the
> normal routing process or drop it?

> > > if router B has following config:
> > > interface Serial0
> > > ip policy route-map Albert
> > > !
> > > access-list 1 permit 172.16.0.0 0.0.255.255
> > > access-list 2 permit 172.17.0.0 0.0.255.255
> > > !
> > > route-map Albert permit 10
> > > match ip address 1
> > > set ip next-hop 10.1.2.3
> > > !
> > > route-map Albert permit 20
> > > match ip address 2
> > > set ip next-hop 10.1.2.2

> > > If router A fail,the packet which source is 172.16.0.0/16 should drop
by
> > > router B or send to LAN by router B?
> > > If router B know this(router A fail),can router B put the packet to
the
> > > normal routing process(like dynamic routing)

> > > thanks! any comment is appreciated.

> > This won't solve anything because you'll still have a route to 10.1.2.3
> even
> > if Router A has failed.
> > The reason why you'll still have a route to 10.1.2.3 is because the
> Ethernet
> > 0 interface on router B is up.
> > You could either use dynamic routing protocol or a static route to a
> > connected interface (I believe)

> > Thomas

 
 
 

static routing and route-map

Post by henr » Fri, 24 Jan 2003 10:07:01


cisco document said:
"Configuring the set ip next-hop command causes the system to use
policy routing first and then use the routing table. "

I don't know it means if next-hop is down,then router will use the routing
table to route the
packet(normal process).
Or it means router will use the routing table to find the next-hop which
specified in the route-map.
which explain is correct? thanks !

> Normal routing I believe: less specific path or even a default path

> Mr T



> > I have another question.
> > If router B loose route to 10.1.2.3,can router B put the packet to the
> > normal routing process or drop it?

> > > > if router B has following config:
> > > > interface Serial0
> > > > ip policy route-map Albert
> > > > !
> > > > access-list 1 permit 172.16.0.0 0.0.255.255
> > > > access-list 2 permit 172.17.0.0 0.0.255.255
> > > > !
> > > > route-map Albert permit 10
> > > > match ip address 1
> > > > set ip next-hop 10.1.2.3
> > > > !
> > > > route-map Albert permit 20
> > > > match ip address 2
> > > > set ip next-hop 10.1.2.2

> > > > If router A fail,the packet which source is 172.16.0.0/16 should
drop
> by
> > > > router B or send to LAN by router B?
> > > > If router B know this(router A fail),can router B put the packet to
> the
> > > > normal routing process(like dynamic routing)

> > > > thanks! any comment is appreciated.

> > > This won't solve anything because you'll still have a route to
10.1.2.3
> > even
> > > if Router A has failed.
> > > The reason why you'll still have a route to 10.1.2.3 is because the
> > Ethernet
> > > 0 interface on router B is up.
> > > You could either use dynamic routing protocol or a static route to a
> > > connected interface (I believe)

> > > Thomas

 
 
 

static routing and route-map

Post by Thomas Kubor » Fri, 24 Jan 2003 17:17:05


see in-line

Quote:> "Configuring the set ip next-hop command causes the system to use
> policy routing first and then use the routing table. "

> I don't know it means if next-hop is down,then router will use the routing
> table to route the packet(normal process).

correct. this is how route-map works for policy routing.
If there's a match, PBR is applied. If not, PBR is not applied & the packet
is routed normally.
It is different for route redistribution where if there's a match, the route
is redistributed & if not, the route is not redistributed (dropped)

Quote:> Or it means router will use the routing table to find the next-hop which
> specified in the route-map.
> which explain is correct? thanks !

nope
 
 
 

static routing and route-map

Post by henr » Sat, 25 Jan 2003 18:34:43


thanks!

Quote:> see in-line

> > "Configuring the set ip next-hop command causes the system to use
> > policy routing first and then use the routing table. "

> > I don't know it means if next-hop is down,then router will use the
routing
> > table to route the packet(normal process).

> correct. this is how route-map works for policy routing.
> If there's a match, PBR is applied. If not, PBR is not applied & the
packet
> is routed normally.
> It is different for route redistribution where if there's a match, the
route
> is redistributed & if not, the route is not redistributed (dropped)

> > Or it means router will use the routing table to find the next-hop which
> > specified in the route-map.
> > which explain is correct? thanks !

> nope

 
 
 

1. Floating static routes, admin. distance and route-map

I will rephrase an earlier question I had, in the hope that someone may
know how to achieve this, and based on some reading I did, from Cisco's
web site:

I have right now a setup with two routers, using two lines connecting
them, where I have the traffic statically segregated, using a combination
of static routes and route-map rules (i.e. on one router I statically
point to a few systems on the other side, through one line, and default to
the second, while - correspondingly - I route-map the source addresses of
the hosts behind the other router, through the first line, and default the
rest through the second)

I would like to use the two lines - obviously, both active - in such a way
that if one fails, the other would "pick up" all the traffic, so - the
way I see it right now the question would be: can I combine route-mapping
and administrative distances (under the assumption that administrative
distance would take care of the traffic being segregated as I have it now,
and still provide a "failover" path, in case of one line being down)?

I would appreciate comments, or pointers to a configuration achieving the
above.

TIA,
C

2. FP2000 Publishing Question

3. help with route-maps controlling static route distribution

4. Printing PDFs automatically

5. route-map question (how to policy route for all destinations except few subnets?)

6. LOW PRICE Commodore Amiga & NewTek Harware And Software Amiga Dealer Closeout !

7. route-map -> pre or post routing?

8. replacing access-list for route-map (policy routing)

9. OSPF route-map route-tag

10. route-map + ARP = routing problems?

11. Select default route using route-map?

12. Using route-map to route packets coming from different networks.