Send document comments to nexus7k-docfeedback@cisco.com.
17-6
Cisco Nexus 7000 Series NX-OS Unicast Routing Configuration Guide, Release 4.x
OL-20002-02
Chapter 17      Configuring Policy-Based Routing
Configuring Policy-Based Routing
The following example shows how to add a route map to an interface:
switch# config t
switch(config)# interface ethernet 1/2
switch(config-if)# ip policy route-map Testmap
switch(config)# exit
switch(config)# copy running-config startup-config
You can configure the following optional match parameters for route maps in route-map configuration 
mode:
You can configure the following optional set parameters for route maps in route-map configuration 
mode:
Command Purpose
match ip address access-list-name 
name
 
[
name...
]
Example:
switch(config-route-map)# match ip address 
access-list-name ACL1
Match an IPv4 address against one or more IP 
access control lists (ACLs). This command is used 
for policy-based routing and ignored by route 
filtering or redistribution.
match ipv6 address access-list-name 
name
 
[
name...
]
Example:
switch(config-route-map)# match ipv6 
address access-list-name ACLv6
Match an IPv6 address against one or more IPv6 
ACLs. This command is used for policy-based 
routing and ignored by route filtering or 
redistribution.
match length 
min max
Example:
switch(config-route-map)# match length 64 
1500
Match against the length of the packet. This 
command is used for policy-based routing.
Command Purpose
set ip next-hop 
address1
 [
address2...
] 
{load-share | peer-address} 
Example:
switch(config-route-map)# set ip next-hop 
192.0.2.1
Sets the IPv4 next-hop address for policy-based 
routing. This command uses the first valid next-hop 
address if multiple addresses are configured. 
Use the optional load-share keyword to load 
balance traffic across up to 16 next-hop addresses.
set ip default next-hop 
address1
 
[
address2...
] {load-share}
Example:
switch(config-route-map)# set ip default 
next-hop 192.0.2.2
Sets the IPv4 next-hop address for policy-based 
routing when there is no explicit route to a 
destination. This command uses the first valid 
next-hop address if multiple addresses are 
configured.
Use the optional load-share keyword to load 
balance traffic across up to 16 next-hop addresses.