Configuring Match and Set Clauses
Upon entering a route-map sequence, you are placed in route-map configuration command mode. Match and set clauses are configured in route-map configuration command mode.
A route-map sequence‘s match clause specifies the criterion that determines whether the action for this route-map will occur. The following types of match clauses are supported:
Redistribution Match Clauses
- A match clause that matches packets egressing on this interface with the statements in up to five specified ACLs. Multiple clauses may be used. At least one of the ACLs in each clause must match the packet in order for the route-map to redirect the packet. The only limit on the number of ACLs supported is the system limit of 1000 route-map clauses. Use the match ip address command in redistribution route-map configuration command mode to specify up to five ACLs for this match clause.
- An interface match clause that matches the source IP address of a packet egressing on this interface against a specified VLAN interface. Use the match interface command in redistribution route-map configuration command mode to specify a VLAN interface for this match clause.
- A metric match clause that matches the specified or a range of cost against the route cost specified in the packet. Use the match metric command in redistribution route-map configuration command mode to specify the metric cost for this match clause.
- An OSPF tag match clause that matches the specified OSPF tag or range of tags against the OSPF tag ID specified in the packet. Use the match tag command is redistribution route-map configuration command mode to specify the OSPF tag ID for this match clause.
Policy Match Clauses
An IP address match clause that matches the source IP address of a packet egressing on this interface with the statements in up to five specified ACLs in the case of S- and K-Series or in a single ACL for the 7100-Series. The IP address match clause can be entered for both a policy based route-map and a redistribution route-map.
Use the match ip address command in policy-based route-map configuration command mode to specify up to five ACLs for the S- and K-Series, or a single ACL for the 7100-Series, to be associated with this match clause. On the S- and K-Series, multiple clauses may be used. At least one of the ACLs in each clause must match the packet in order for the route-map to redirect the packet. On the 7100-Series, the ACL must match the packet in order for the route-map to redirect the packet.
OSPF Filter Match Clauses
- An IP match clause that matches a route network address, next hop or source router ID against the route to be entered into the OSPF routing table. Use the match ip command in filter-based route-map configuration command mode to specify up to five ACLs for S- and K-Series or a single ACL for the 7100-Series to be associated with this match clause. For the S- and K-Series, multiple clauses may be used. At least one of the ACLs in each clause must match the packet in order for the route-map to redirect the packet. For the 7100-Series, the ACL must match the packet in order for the route-map to redirect the packet.
- An interface match clause that matches the outgoing interface of the route to be installed in the OSPF routing table. Use the match interface command in filter-based route-map configuration command mode to specify an outgoing interface for this match clause.
- A OSPF tag match clause that matches the OSPF tag for this route. Use the match tag command in filter-based route-map configuration command mode to specify an OSPF tag or range of tags for this match clause.
- A metric match clause that matches the OSPF cost metric for this route. Use the match metric command in filter-based route-map configuration command mode to specify an OSPF route cost metric or range of cost metrics for this match clause.
- A route-type match clause that matches the internal or external route type for this route. Use the match route-type command in filter-based route-map configuration command mode to specify an OSPF route-type for this match clause.
There can be multiple match clauses associated with a single route-map sequence.
A route-map sequence‘s set clause determines the action the route-map will take when a successful match for this sequence occurs. The action configurable for a set clause depends upon the route-map type. For a policy based route-map, the set clause specifies one or more next hops for this route. For the redistribution route-map, the set clause specifies an OSPF route tag for this route.