Cisco Systems 4500 Switch User Manual


  Open as PDF
of 1504
 
35-7
Software Configuration Guide—Release 15.0(2)SG
OL-23818-01
Chapter 35 Configuring Policy-Based Routing
Policy-Based Routing Configuration Tasks
Step 4
Switch(config-route-map)# set interface
interface-type interface-number
[... type number]
Or
Specifies the output interface from which the packet will be
sent. This action specifies that the packet is forwarded out of
the local interface. The interface must be a Layer 3 interface
(not a switchport).
Packets are forwarded on the specified interface only if one
of the following conditions is met:
The destination IP address in the packet lies within the IP
subnet to which the specified interface belongs.
The destination IP address in the packet is reachable
through the specified interface (as per the IP routing
table).
If the destination IP address on the packet does not meet
either of these conditions, the packet is dropped. This action
forces matching packets to be switched in software.k
Step 5
Switch(config-route-map)# set ip default
next-hop ip-address [... ip-address]
Or
Sets next hop to which to route the packet if there is no
explicit route for the destination IP address in the packet.
Before forwarding the packet to the next hop, the switch looks
up the packet’s destination address in the unicast routing
table. If a match is found, the packet is forwarded by way of
the routing table. If no match is found, the packet is forwarded
to the specified next hop.
Step 6
Switch(config-route-map)# set default
interface interface-type interface-number
[...type ...number]
Specifies the output interface from which the packet will be
sent if there is no explicit route for this destination. Before
forwarding the packet to the next hop, the switch looks up the
packet’s destination address in the unicast routing table. If a
match is found, the packet is forwarded by using the routing
table. If no match is found, the packet is forwarded to the
specified output interface.
Packets are forwarded on the specified interface only if one
of the following conditions is met:
The destination IP address in the packet lies within the IP
subnet to which the specified interface belongs.
The destination IP address in the packet is reachable
through the specified interface (as per the IP routing
table).
If the destination IP address on the packet does not meet
either of these conditions, the packet is dropped. This action
forces matching packets to be switched in software.
Step 7
Switch(config-route-map)# interface
interface-type interface-number
Specifies the interface. This command puts the switch into
interface configuration mode.
Step 8
Switch(config-if)# ip policy route-map map-tag
Identifies the route map to use for PBR. One interface can
only have one route map tag, but you can have multiple route
map entries with different sequence numbers. These entries
are evaluated in sequence number order until the first match.
If no match exists, packets are routed as usual.
Command Purpose