Re: Route-Map clarification

From: Yuri Bank <yuribank_at_gmail.com>
Date: Wed, 29 Feb 2012 16:43:37 -0800

Multiple match statements for a prefix-list in a single route-map sequence
will not act as an AND. If you attempt to do this, it will act as a single
match statement, and match ANY of the prefix-lists.

Example:

R2(config)#ip prefix-list A5 permit 50.0.0.0/16
R2(config)#ip prefix-list A4 permit 40.0.0.0/16

R2(config)#route-map DEFAULT permit 10
R2(config-route-map)#match ip address prefix-list A5
R2(config-route-map)#match ip address prefix-list A4

R2#show route-map
route-map DEFAULT, permit, sequence 10
  Match clauses:
    ip address prefix-lists: A5 A4
  Set clauses:
  Policy routing matches: 0 packets, 0 bytes
R2#

This will return true if either prefix-list is matched. A5 OR A4

-Yuri

On Wed, Feb 29, 2012 at 2:57 PM, marc abel <marcabel_at_gmail.com> wrote:

> *slaps forhead. Right! Not enough coffee this morning. :)
>
> On Wed, Feb 29, 2012 at 4:48 PM, Ben Hughes <bhughes_at_imc.net.au> wrote:
>
> > Marc/Vincent,
> >
> > There is no match-any for a route-map (this is for class-maps). The
> logic
> > is an AND for multiple match statements in a route-map. Therefore case
> #1
> > won't match anything and case #2 will match either.
> >
> > cheers,
> > Ben.
> >
> > From: marc abel <marcabel_at_gmail.com<mailto:marcabel_at_gmail.com>>
> > Reply-To: marc abel <marcabel_at_gmail.com<mailto:marcabel_at_gmail.com>>
> > Date: Wed, 29 Feb 2012 09:22:30 -0600
> > To: Vincent Tay <vtay.75_at_gmail.com<mailto:vtay.75_at_gmail.com>>
> > Cc: "Ccielab_at_groupstudy.com<mailto:Ccielab_at_groupstudy.com>" <
> > ccielab_at_groupstudy.com<mailto:ccielab_at_groupstudy.com>>
> > Subject: Re: Route-Map clarification
> >
> > route-map CONDITIONAL
> > match ip address prefix R1
> > match ip address prefix R2
> >
> > This won't match anything because the default is match all. A prefix
> can't
> > match both. You probably want:
> >
> > route-map match-any CONDITIONAL
> > match ip address prefix R1
> > match ip address prefix R2
> >
> >
> > -Marc
> >
> > On Tue, Feb 28, 2012 at 7:23 AM, Vincent Tay <vtay.75_at_gmail.com<mailto:
> > vtay.75_at_gmail.com>> wrote:
> >
> > Hi all,
> >
> > Can any explain the below differences?
> >
> > *CASE 1*
> >
> > ip prefix-list R1 permit 164.1.13.0/24
> > ip prefix-list R2 permit 164.1.23.0/24
> >
> > route-map CONDITIONAL
> > match ip address prefix R1 * -> Is this suppose to be match
> > prefix R1 AND R2?*
> > match ip address prefix R2
> >
> > router ospf 1
> > default-information originate route-map CONDITIONAL
> >
> > *CASE 2*
> >
> > ip prefix-list R1_OR_R2 permit 164.1.13.0/24
> > ip prefix-list R1_OR_R2 permit 164.1.23.0/24
> >
> > route-map CONDITIONAL
> > match ip address prefix R1_OR_R2
> >
> >
> > router ospf 1
> > default-information originate route-map CONDITIONAL
> >
> >
> > Blogs and organic groups at http://www.ccie.net
> >
> > _______________________________________________________________________
> > Subscription information may be found at:
> > http://www.groupstudy.com/list/CCIELab.html
> >
> >
> > Blogs and organic groups at http://www.ccie.net
> >
> > _______________________________________________________________________
> > Subscription information may be found at:
> > http://www.groupstudy.com/list/CCIELab.html
>
>
> Blogs and organic groups at http://www.ccie.net
>
> _______________________________________________________________________
> Subscription information may be found at:
> http://www.groupstudy.com/list/CCIELab.html

Blogs and organic groups at http://www.ccie.net
Received on Wed Feb 29 2012 - 16:43:37 ART

This archive was generated by hypermail 2.2.0 : Thu Mar 01 2012 - 11:46:56 ART