Policy-Based Routing Configuration Examples - Cisco Catalyst 4500 series Administration Manual

Hide thumbs Also See for Catalyst 4500 series:
Table of Contents

Advertisement

Policy-Based Routing Configuration Examples

Note
Policy-Based Routing Configuration Examples
The following sections provide PBR configuration examples:
For information on how to configure policy-based routing, see the section
Configuration Tasks"
Equal Access
The following example provides two sources with equal access to two different service providers.
Packets arriving on interface fastethernet 3/1 from the source 1.1.1.1 are sent to the switch at 6.6.6.6 if
the switch has no explicit route for the destination of the packet. Packets arriving from the source 2.2.2.2
are sent to the switch at 7.7.7.7 if the switch has no explicit route for the destination of the packet. All
other packets for which the switch has no explicit route to the destination are discarded.
Switch (config)# access-list 1 permit ip 1.1.1.1
access-list 1 permit ip 1.1.1.1
!
interface fastethernet 3/1
ip policy route-map equal-access
!
route-map equal-access permit 10
match ip address 1
set ip default next-hop 6.6.6.6
route-map equal-access permit 20
match ip address 2
set ip default next-hop 7.7.7.7
route-map equal-access permit 30
set default interface null0
If the packets you want to drop do not match either of the first two route-map clauses, then change |
Note
set default interface null0 to set interface null0.
Differing Next Hops
The following example illustrates how to route traffic from different sources to different places (next
hops). Packets arriving from source 1.1.1.1 are sent to the next hop at 3.3.3.3; packets arriving from
source 2.2.2.2 are sent to the next hop at 3.3.3.5.
access-list 1 permit ip 1.1.1.1
access-list 2 permit ip 2.2.2.2
!
Software Configuration Guide—Release IOS XE 3.6.0E and IOS 15.2(2)E
40-12
set ip next-hop recursive ip-address
The recursive option is not supported on IPv6.
Equal Access, page 40-12
Differing Next Hops, page 40-12
Deny ACE, page 40-13
in this chapter.
Chapter 40
Configuring Policy-Based Routing
"Policy-Based Routing
OL_28731-01

Advertisement

Table of Contents
loading

Table of Contents