Show Commands

This chapter describes the Cisco NX-OS Policy Based Routing (PBR) show commands.

show ip policy

To display the route policy information, use the show ip policy command.

show ip policy [vrf vrf-name ]

 
Syntax Description

vrf vrf-name

(Optional) Specifies the name of the virtual routing and forwarding (VRF) instance. The vrf-name argument can be specified as any case-insensitive alphanumeric string up to 32 characters. The strings “default” and “all” are reserved VRF names.

 
Command Default

None

 
Command Modes

Any

 
Supported User Roles

network-admin
vdc-admin

 
Command History

Release
Modified

6.0(2)N2(1)

This command was introduced.

 
Usage Guidelines

This command does not require a license.

Examples

This example shows the policies attached to interfaces:

switch(config)# show ip policy
Interface Route-map Status VRF-name
Eternet2/45 floor1 Inactive --

 

Command
Description

ip policy

Configures a route policy on an interface.

show ipv6 policy

To display the route policy information, use the show ipv6 policy command.

show ipv6 policy vrf vrf-name

 
Syntax Description

vrf-name

(Optional) Specifies the name of the virtual routing and forwarding (VRF) instance. The vrf-name argument can be specified as any case-insensitive alphanumeric string up to 32 characters. The strings “default” and “all” are reserved VRF names.

 
Command Default

None

 
Command Modes

Any

 
Supported User Roles

network-admin
vdc-admin

 
Command History

Release
Modified

6.0(2)N2(1)

This command was introduced.

 
Usage Guidelines

This command does not require a license.

Examples

This example shows the policies attached to interfaces:

switch(config)# show ipv6 policy
Interfaces Route-map Status VRF-Name
Ethernet2/45 floor1 Inactive --

 

Command
Description

show ip policy

Displays route policy information.

set ipv6 next-hop

To indicate where to output packets that pass a match clause of a route map for policy routing, use the set ipv6 next-hop command in route-map configuration mode. To delete an entry, use the no form of this command.

set ipv6 next-hop { ipv6-address [... ipv6 - address ]}

no set ipv6 next-hop { ipv6-address [... ip v6- address ]}

 
Syntax Description

ipv6 address

IPv6 address of the next hop to which packets are output. It need not be an adjacent router. You can configure one or more IP addresses.

 
Command Default

This command is disabled by default.

 
Command Modes

Route-map configuration (config-route-map)

 
Supported User Roles

network-admin
vdc-admin

 
Command History

Release
Modified

6.0(2)N2(1)

This command was introduced.

 
Usage Guidelines

An ellipsis (...) in the command syntax indicates that your command input can include multiple values for the ip-address argument.

Use the ipv6 policy route-map command and the match and set commands to define the conditions for policy routing packets. The ipv6 policy route-map command identifies a route map by name. Each route-map command has a list of match and set commands associated with it. The match commands specify the match criteria—the conditions under which policy routing occurs. The set commands specify the set actions—the particular routing actions to perform if the criteria enforced by the match commands are met.

If the first next hop specified with the set ipv6 next-hop command is down, the optionally specified IP addresses are tried in turn.

This command does not require a license.

Examples

This example shows how to configure a route map that sets the IPv6 next-hop address:

switch(config)# ipv6 access-list test
switch(config-ipv6-acl)# permit ipv6 2001:0DB8::/48 any
switch(config-ipv6-acl)# exit
switch(config)# route-map equal-access

switch(config-route-map)# match ipv6 address test

switch(config-route-map)# set ipv6 next-hop 2001:0DB8::3

switch(config-route-map))# exit

switch(config)# interface externet 2/1

switch(config-if)# ipv6 policy route-map equal-access

 

Command
Description

match ipv6 address

Distributes any routes that have a destination network number address that is permitted by a standard or expanded access list, and performs policy routing on packets.

match ipv6 next-hop

Redistributes any routes that have a next-hop router address passed by one of the access lists specified.

route-map

Defines the conditions for redistributing routes from one routing protocol into another, or enables policy routing.