Configuring an IPv6 PBR with IPv6 address as the next hop

The following steps configure an IPv6 PBR by setting an IPv6 address as the next hop in the route map.

Note

Note

This task uses access-control lists (ACLs). For details about configuring ACLs, see the "ACLs" section of this publication.
  1. Enter the configure terminal command to enter global configuration mode.
    device# configure terminal
  2. Define the required IPv6 ACLs to be added to the route map.
    device(config)# ipv6 access-list standard 99
    device(conf-ip6acl-std)# permit any
  3. Enter the exit command to return to global configuration mode.
    device(conf-ip6acl-std)# exit
  4. Enter the route-map command to define the route and specify the match criteria and the resulting action if all the match clauses are met.
    device(config)# route-map test-route permit 99
  5. Add IPv6 ACLs to match the IP address that is permitted by the ACL.
    device(config-route-map-test-route/permit/99)# match ipv6 address acl 99
  6. Set the IPv6 address of the next hop to which the traffic that matches a match statement in the route map must be routed.
    device(config-route-map-test-route/permit/99)# set ipv6 next-hop 2001:db8:0:0:0:ff00:42:8329
  7. Enter the exit command to return to the global configuration mode.
    device(config-route-map-test-route/permit/99)# exit
  8. Enable IPv6 PBR by applying the route map on an interface or on virtual interface.
    • Enable IPv6 PBR by applying the route map on an interface.
      device(config)# interface ethernet 1/1
      device(conf-if-eth-1/1)# ipv6 policy route-map test-route
    • Enable IPv6 PBR by applying the route map on a virtual interface.
      device(config)# interface Ve 1
      device(config-if-Ve-1)# ipv6 policy route-map test-route

Example

The following example shows the configuration steps to configure an IPv6 PBR by setting an IPv6 address as the next hop in the route map.

Example

device# configure terminal
device(config)# ipv6 access-list standard 99
device(conf-ip6acl-std)# permit any
device(conf-ip6acl-std)# exit
device(config)# route-map test-route permit 99
device(config-route-map-test-route/permit/99)# match ipv6 address acl 99
device(config-route-map-test-route/permit/99)# set ipv6 next-hop 2001:db8:0:0:0:ff00:42:8329
device(config-route-map-test-route/permit/99)# exit
device(config)# interface ethernet 1/1
device(conf-if-eth-1/1)# ipv6 policy route-map test-route
device(conf-if-eth-1/1)# end