- A virtual community of network engineers
 Home  BookStore  StudyNotes  Links  Archives  StudyRooms  HelpWanted  Discounts  Login
RE: routing sequence [7:131928] posted 07/16/2008
[Chronological Index] [Thread Index] [Top] [Date Prev][Date Next] [Thread Prev][Thread Next]

You are correct.  Unfortunately, that is right.

I had my vendors a bit mixed up, as the last time I demonstrated that
functionality was on Juniper routers not Cisco ones.

So the underlying rule is that longest-prefix match ALWAYS wins.


-----Original Message-----
From: nobody@xxxxxxxxxxxxxx [mailto:nobody@xxxxxxxxxxxxxx] On Behalf Of
Ibrahim Abo Zaid
Sent: Wednesday, July 16, 2008 4:40 AM
To: cisco@xxxxxxxxxxxxxx
Subject: Re: routing sequence [7:131928]

Hi Scott

I labed the  below trick and it verifies that longest match always wins as
you state but i have a small comment

when configuring local interface with less spessific address 172.16.1./24and
have a more spesific route , ping goes to more spesific route not local
interface as you state . i just want to ensure this is right .

thank you

On Wed, Jul 16, 2008 at 3:58 AM, Paul Yeo  wrote:

> Thank you very much Iain, Scott and all,
> I really need to brush up this...I am confused at times.
> Thanks much!
> -----Original Message-----
> From: nobody@xxxxxxxxxxxxxx [mailto:nobody@xxxxxxxxxxxxxx] On Behalf 
> Of Scott Morris
> Sent: Tuesday, July 15, 2008 6:58 PM
> To: cisco@xxxxxxxxxxxxxx
> Subject: RE: routing sequence [7:131928]
> PBR is actually done first.  This technically AVOIDS the routing 
> process (manual routing).
> Otherwise, most-specific matching is done on your route.  (longest 
> prefix
> match)
> If you have more than one protocol (static or dynamic) that gives the 
> same prefix, administrative distance (AD) is used to select the best 
> path.  If different AD values, only one will appear in "show ip route"
> So you can play some interesting tricks with that.  Namely you can 
> have a connected interface (which logically trumps everything) 
> configured as  "ip address" and then you have 
> a route (static or dynamic doesn't matter) for 
> ( pointing to another router.  This is a more specific
> Now, if you ping that's your local interface IP.  It will go 
> locally.
> If you ping, it will go to a remote router because 
> more specific than
> If you ping, it will go to the directly connected interface.
> Kinda messes with your head sometimes!  But the bottom line is most 
> specific match wins!
> HTH,
> Scott Morris, CCIE4 #4713, JNCIE-M #153, JNCIS-ER, CISSP, et al.
> Senior CCIE Instructor
> smorris@xxxxxxxxxxxxxxxxxxxxxx
> Internetwork Expert, Inc.
> Toll Free: 877-224-8987
> Outside US: 775-826-4344
> Online Community:
> CCIE Blog:
> Knowledge is power.
> Power corrupts.
> Study hard and be Eeeeviiiil......
> -----Original Message-----
> From: nobody@xxxxxxxxxxxxxx [mailto:nobody@xxxxxxxxxxxxxx] On Behalf 
> Of Paul Yeo
> Sent: Tuesday, July 15, 2008 2:00 AM
> To: cisco@xxxxxxxxxxxxxx
> Subject: routing sequence [7:131928]
> Hi folks,
> Am I understood this correctly, the routing will process in this way:
> 1) very specific static route - e.g.
> 2) general static route --- e.g.
> 3) routing protocol route - e.g. eigrp
> 4) pbr
> I have a remote router configured with a very specific route than my 
> central router, it seems that the router actually choose the remote 
> router to route to the destination.
> Tx,

Message Posted at:
FAQ, list archives, and subscription info: