• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 604
  • Last Modified:

understanding Route-Map Sequences

I would like to know when the Route Map means AND and when it Means OR:

For instance:

Route-Map OSPF2EIGRP 10
Match tag 5
Match Route-Type Internal
Does this mean match them both or the condition is false.
=======
Route-Map OSPF2EIGRP 10
Match tag 5

Route-Map OSPF2EIGRP 10
Match Route-Type Internal

Does this mean Match either the routes with tag 5 OR type Internal ?
=======

Thank you
0
jskfan
Asked:
jskfan
  • 2
  • 2
  • 2
  • +2
6 Solutions
 
Garry GlendownConsulting and Network/Security SpecialistCommented:
If you have multiple match commands in a single route-map entry, all must match for that entry to be "true". The second example, I don't understand - there can only be one entry with sequence "10" at the same time. If you want a logical "or", you will need to create to separate entries with different sequence numbers, with the same "set" statements in it.
0
 
SandyCommented:
yups, all must match.
0
 
thpipfhCommented:
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
Jody LemoineNetwork ArchitectCommented:
Multiple match statements in the same sequence are AND. If you want to do OR, you use different sequences. To use an example for overloaded NAT on multiple interfaces:

object-group network og-rfc-1918
 10.0.0.0 255.0.0.0
 172.16.0.0 255.240.0.0
 192.168.0.0 255.255.0.0
!
ip access-list extended acl-nat
 deny ip object-group og-rfc1918 object-group og-rfc1918
 permit ip object-group og-rfc1918 any
!
route-map rm-internet permit 10
 match ip address acl-nat
 match interface GigabitEthernet0/0
!
route-map rm-internet permit 20
 match ip address acl-nat
 match interface GigabitEthernet0/1

The first sequence in the route map requires that the traffic match acl-nat AND that it be leaving the router via interface GigabitEthernet0/0. The second sequence catches traffic that matches acl-nat AND leaving the router via interface GigabitEthernet0/1. Within a single sequence, everything is AND. Collectively, the sequences allow the entire route map to cover traffic leaving via GigabitEthernet0/0 OR GigabitEthernet0/1.
0
 
Jody LemoineNetwork ArchitectCommented:
If you enter the configuration in your question:

Route-Map OSPF2EIGRP 10
Match tag 5

Route-Map OSPF2EIGRP 10
Match Route-Type Internal

You'll get the following in your configuration:

Route-Map OSPF2EIGRP 10
Match tag 5
Match Route-Type Internal

This is an AND comparison. If you want OR, you'll have to use different sequences. The only time you can do OR in the same sequence is if you're matching multiple items on the same line:

route-map OSPF2EIGRP
 match tag 5 10 15 20
 match route-type internal

That sequence will require that the route be tagged with (5, 10, 15 OR 20) AND be an internal route.
0
 
jskfanAuthor Commented:
Sorry for the typo in the OR case:

Route-Map OSPF2EIGRP 10
Match tag 5
Match Route-Type Internal
=======
Route-Map OSPF2EIGRP 10
Match tag 5

Route-Map OSPF2EIGRP 20
Match Route-Type Internal
=====================================

So Multiple Match in one sequence is an AND
Multiple match in difference sequences is an OR

Correct?
0
 
Garry GlendownConsulting and Network/Security SpecialistCommented:
Correct ...
For the "or" case, just make sure you have the appropriate/required set-operations like next hop, etc. in sync ...
0
 
jskfanAuthor Commented:
thank you
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 2
  • 2
  • 2
  • +2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now