Professional Documents
Culture Documents
Once again
Topics
Process
Switching
Control Plane
IP Routing Table
CPU
Ingress Interface
1 Packet
2nd Packet
3rd Packet
4th Packet
5th Packet
st
Data Plane
Egress Interface
Fast Switching
Ingress Interface
1 Packet
2nd Packet
3rd Packet
4th Packet
5th Packet
Data Plane
st
Egress Interface
Fast
Forward
Cache
CEF Switching
CPU
Ingress Interface
1 Packet
2nd Packet
3rd Packet
4th Packet
5th Packet
st
Data Plane
Egress Interface
FIB and
Adjacency
Table
CEF
HQ#showipcef
Prefix
0.0.0.0/0
0.0.0.0/8
0.0.0.0/32
10.10.10.0/30
10.10.10.0/32
10.10.10.1/32
10.10.10.3/32
127.0.0.0/8
192.168.100.0/24
192.168.100.0/32
192.168.100.1/32
192.168.100.255/32
224.0.0.0/4
224.0.0.0/24
240.0.0.0/4
255.255.255.255/32
HQ#
NextHop
noroute
drop
receive
attached
receive
receive
receive
drop
attached
receive
receive
receive
drop
receive
drop
receive
Interface
Ethernet0/0
Ethernet0/0
Ethernet0/0
Ethernet0/0
Ethernet0/1
Ethernet0/1
Ethernet0/1
Ethernet0/1
Every entry in the routing table has a preconfigured entry in the FIB table.
HQ is currently not configured with any routing protocol.
10
HQ#showadjacency
ProtocolInterface
Address
HQ#
HQ#ping10.10.10.2
Typeescapesequencetoabort.
Sending5,100byteICMPEchosto10.10.10.2,timeoutis2seconds:
.!!!!
Successrateis80percent(4/5),roundtripmin/avg/max=1/1/1ms
HQ#
HQ#showadjacency
Protocol
Interface
Address
IP
Ethernet0/0
10.10.10.2(7)
HQ#showipcef
Prefix
NextHop
Interface
0.0.0.0/0
noroute
0.0.0.0/8
drop
0.0.0.0/32
receive
10.10.10.0/30
attached
Ethernet0/0
10.10.10.0/32
receive
Ethernet0/0
10.10.10.1/32
receive
Ethernet0/0
10.10.10.2/32
attached
Ethernet0/0
11
HQ(config)#routereigrp1
HQ(configrouter)#network192.168.100.00.0.0.255
HQ(configrouter)#network10.10.10.00.0.0.3
*Jul2916:35:15.745:%DUAL5NBRCHANGE:EIGRPIPv41:Neighbor10.10.10.2
(Ethernet0/0)isup:newadjacency
HQ#showiprouteeigrp
D192.168.110.0/24[90/307200]via10.10.10.2,00:03:17,Ethernet0/0
HQ#
HQ#showadjacency
Protocol
Interface
Address
IP
Ethernet0/0
10.10.10.2(11)
HQ#showipcef
Prefix
NextHop
Interface
<partialoutput>
192.168.110.0/24
10.10.10.2
Ethernet0/0
12
R1
HQ(config)#interfaceethernet0/0
HQ(configif)#noiproutecachecef
HQ(configif)#^Z
HQ#
*Jul2917:10:14.737:%SYS5CONFIG_I:Configuredfromconsolebyconsole
HQ#showipinterfaceethernet0/0|includeswitching
IPfastswitchingisenabled
IPfastswitchingonthesameinterfaceisdisabled
IPFlowswitchingisdisabled
IPCEFswitchingisdisabled
IPmulticastfastswitchingisenabled
IPmulticastdistributedfastswitchingisdisabled
HQ#
HQ#showipcef
Prefix
NextHop
Interface
0.0.0.0/0
noroute
0.0.0.0/8
drop
0.0.0.0/32
receive
10.10.10.0/30
attached
Ethernet0/0
<omitted>
HQ(config)#noipcef
HQ(config)#end
HQ#
*Jul2917:14:36.676:%SYS5CONFIG_I:Configuredfromconsolebyconsole
HQ#showipcef
%IPv4CEFnotrunning
HQ#
16
17
Path control tools can be used to change the default destination forwarding
and optimize the path of the packets for some specific application
Path Control is controlling the path that traffic takes through a network when
there are:
Redundant paths
Asymmetric paths (form of redundancy)
Three tools for path control are detailed:
Cisco IOS IP service level agreements (SLAs)
Policy Based Routing (PBR)
18
19
21
22
172.16.2.1/24
Schroeder
172.16.4.1/24
Linus
S0
E0
172.16.4.3/24
172.16.3.1/24
Pigpen
Charlie
172.16.1.1/24
172.16.6.1/24
172.16.7.1/24
172.16.1.2/24
172.16.8.1/24
Lucy
172.16.4.2/24
172.16.2.1/24
Schroeder
172.16.4.1/24
Linus
S0
E0
172.16.4.3/24
172.16.3.1/24
Pigpen
Charlie
172.16.1.1/24
Linus:
172.16.6.1/24
172.16.7.1/24
inter S0
ip policy route-map Sally
route-map Sally permit 10
match ip address 1
set ip next-hop 172.16.4.2
route-map Sally permit 15
match ip address 2
set ip next-hop 172.16.4.3
172.16.1.2/24
172.16.8.1/24
24
172.16.2.1/24
Schroeder
172.16.4.1/24
Linus
S0
E0
172.16.4.3/24
172.16.3.1/24
Pigpen
Charlie
172.16.1.1/24
172.16.6.1/24
172.16.7.1/24
172.16.1.2/24
172.16.8.1/24
Lucy
172.16.4.2/24
172.16.2.1/24
Schroeder
172.16.4.1/24
Linus
S0
E0
172.16.4.3/24
172.16.3.1/24
Pigpen
Charlie
172.16.1.1/24
172.16.6.1/24
172.16.7.1/24
172.16.1.2/24
172.16.8.1/24
Linus:
inter S0
ip policy route-map Sally
route-map Sally permit 10
match ip address 101
set ip next-hop 172.16.4.2
route-map Sally permit 15
match ip address 102
set ip next-hop 172.16.4.3
Book Example
Notebook>traceroute192.168.100.1
Typeescapesequencetoabort.
Tracingtherouteto192.168.100.1
VRFinfo:(vrfinname/id,vrfoutname/id)
1192.168.110.10msec0msec
210.10.20.11msec*1msec
Notebook>
PC>traceroute192.168.100.1
Typeescapesequencetoabort.
Tracingtherouteto192.168.100.1
VRFinfo:(vrfinname/id,vrfoutname/id)
1192.168.110.11msec0msec0msec
210.10.20.11msec*1msec
PC>
27
28
BR1#showroutemap
routemapPBRNotebook,permit,sequence10
Matchclauses:
ipaddress(accesslists):PBRACL
Setclauses:
ipnexthop10.10.20.1
Policyroutingmatches:0packets,0bytes
BR1#showippolicy
Interface
Routemap
Ethernet0/1
PBRNotebook
29
Notebook>traceroute192.168.100.1
Typeescapesequencetoabort.
Tracingtherouteto192.168.100.1
VRFinfo:(vrfinname/id,vrfoutname/id)
1192.168.110.11msec0msec1msec
210.10.20.15msec*5msec
Notebook>
PC>traceroute192.168.100.1
Typeescapesequencetoabort.
Tracingtherouteto192.168.100.1
VRFinfo:(vrfinname/id,vrfoutname/id)
1192.168.110.11msec1msec0msec
210.10.10.11msec*1msec
PC>
30
BR1#debugippolicy
Policyroutingdebuggingison
BR1#
PC>ping192.168.100.1
!!!!!
BR1#
*Aug417:36:42.981:IP:s=192.168.110.20(Ethernet0/1),d=192.168.100.1,
len100,
FIBpolicyrejected(nomatch)normalforwarding
*Aug417:36:42.982:IP:s=192.168.110.20(Ethernet0/1),d=192.168.100.1,
len100,
FIBpolicyrejected(nomatch)normalforwarding
31
BR1#debugippolicy
Policyroutingdebuggingison
BR1#
Notebook>ping192.168.100.1
!!!!!
BR1#
*Aug417:39:53.147:IP:s=192.168.110.10(Ethernet0/1),d=192.168.100.1,
len100,
FIBpolicymatch
*Aug417:39:53.147:IP:s=192.168.110.10(Ethernet0/1),d=192.168.100.1,
len100,
PBRCounted
*Aug417:39:53.147:IP:s=192.168.110.10(Ethernet0/1),d=192.168.100.1,
g=10.10.10.1,len100,FIBpolicyrouted
32
33
34
Cisco IP SLA
35
IP SLAs Operations
There are two types of IP SLAs
operations:
Those in which the target device is
not running the IP SLAs responder
component (such as a web server or
IP host).
IP SLAs
Source
R1
DNS
Server
R2
IP SLAs
Source
R1
IP SLAs
Responder
R2
MIB data retrieved via SNMP
The following steps are required to configure Cisco IOS IP SLA functionality:
Step 1 Define one or more probes
Step 2 Define one or more tracking objects
Step 3 Define the action on tracking object
Note: Effective with Cisco IOS Release 12.4(4)T, 12.2(33)SB, and 12.2(33)SXI,
the ip sla monitor command is replaced by the ip sla command.
49
Router(config)#ipslamonitoroperationnumber
Router(configrtr)#icmpecho{destinationipaddress|destinationhostname}[sourceip
{ipaddress|hostname}|sourceinterfaceinterfacename]
or
Router(configrtr)#typeechoprotocolipIcmpEcho{destinationipaddress|destination
hostname}[sourceipaddr{ipaddress|hostname}|sourceinterfaceinterfacename]
R1(config)# ip sla 1
R1(config-ip-sla)# ?
IP SLAs entry configuration commands:
dhcp
DHCP Operation
dns
DNS Query Operation
exit
Exit Operation Configuration
frame-relay Frame-relay Operation
ftp
FTP Operation
http
HTTP Operation
icmp-echo
ICMP Echo Operation
icmp-jitter ICMP Jitter Operation
path-echo
Path Discovered ICMP Echo Operation
path-jitter Path Discovered ICMP Jitter Operation
slm
SLM Operation
tcp-connect TCP Connect Operation
udp-echo
UDP Echo Operation
udp-jitter
UDP Jitter Operation
voip
Voice Over IP Operation
R1(config-ip-sla)#
50
Although many command options exist, the focus of this section will be on
frequency and timeout commands.
icmp-echo Sub-Commands
Router(config-ip-sla-echo)#
frequency seconds
Set the amount of time a Cisco IOS IP SLAs operation waits for a
response from its request packet.
The milliseconds parameter is the number of milliseconds (ms) the
operation waits to receive a response from its request packet.
Router(config)#ipslamonitoroperationnumber
Router(configrtr)#icmpecho{destinationipaddress|destinationhostname}[sourceip
{ipaddress|hostname}|sourceinterfaceinterfacename]
Router(configrtr)#frequencyseconds
Router(configrtr)#timeoutmillisecond
53
Note:
Effective with Cisco IOS Release 12.4(4)T, 12.2(33)SB, and 12.2(33)SXI,
the ip sla monitor schedule command is replaced by the ip
sla schedule command.
Description
operation-number
life forever
life seconds
start-time
hh:mm[:ss]
Specifies an absolute start time using hour, minute, and (optionally) second.
Use the 24-hour clock notation.
month
day
(Optional) Number of the day (in the range 1 to 31) to start the operation on.
If a day is not specified, the current day is used.
pending
now
after hh:mm:ss
(Optional) Indicates that the operation should start this amount of time after this command was
entered.
ageout seconds
(Optional) Number of seconds to keep the operation in memory when it is not actively collecting
information (default is 0 seconds which means it never ages out).
recurring
(Optional) Indicates that the operation will start automatically at the specified time and for the
specified duration every day.
Router(config)#ipslamonitoroperationnumber
Router(configrtr)#icmpecho{destinationipaddress|destinationhostname}[sourceip
{ipaddress|hostname}|sourceinterfaceinterfacename]
Router(configrtr)#frequencyseconds
Router(configrtr)#timeoutmillisecond
Router(config)#ipslascheduleoperationnumber[life{forever|seconds}][starttime
{hh:mm[:ss][monthday|daymonth]|pending|now|afterhh:mm:ss}][ageout
seconds][recurring]
56
Router(config)#
track object-number ip sla operation-number {state |
reachability}
Parameter
Description
object-number
operation-number
state
reachability
Note:
Effective with Cisco IOS Release 12.4(20)T, 12.2(33)SXI1, 12.2(33)SRE
and Cisco IOS XE Release 2.4, the track rtr command is replaced
by the track ip sla command.
Router(config)#ipslamonitoroperationnumber
Router(configrtr)#icmpecho{destinationipaddress|destinationhostname}[sourceip
{ipaddress|hostname}|sourceinterfaceinterfacename]
Router(configrtr)#frequencyseconds
Router(configrtr)#timeoutmillisecond
Router(config)#ipslascheduleoperationnumber[life{forever|seconds}][starttime
{hh:mm[:ss][monthday|daymonth]|pending|now|afterhh:mm:ss}][ageout
seconds][recurring]
Router(config)#trackobjectnumberipslaoperationnumber{state|reachability}
or
Router(config)#trackobjectnumberrtroperationnumber{state|reachability}
Description
up
down
seconds
Router(config)#ipslamonitoroperationnumber
Router(configrtr)#icmpecho{destinationipaddress|destinationhostname}[sourceip
{ipaddress|hostname}|sourceinterfaceinterfacename]
Router(configrtr)#frequencyseconds
Router(configrtr)#timeoutmillisecond
Router(config)#ipslascheduleoperationnumber[life{forever|seconds}][starttime
{hh:mm[:ss][monthday|daymonth]|pending|now|afterhh:mm:ss}][ageout
seconds][recurring]
Router(config)#trackobjectnumberrtroperationnumber{state|reachability}
Router(configtrack)#delay{upseconds[downseconds]|[upseconds]downseconds}
61
Router(config)#ipslamonitoroperationnumber
Router(configrtr)#icmpecho{destinationipaddress|destinationhostname}[sourceip
{ipaddress|hostname}|sourceinterfaceinterfacename]
Router(configrtr)#frequencyseconds
Router(configrtr)#timeoutmillisecond
Router(config)#ipslascheduleoperationnumber[life{forever|seconds}][starttime
{hh:mm[:ss][monthday|daymonth]|pending|now|afterhh:mm:ss}][ageout
seconds][recurring]
Router(config)#trackobjectnumberrtroperationnumber{state|reachability}
Router(configtrack)#delay{upseconds[downseconds]|[upseconds]downseconds}
Router(config)#iprouteprefixmask{ipaddress|interfacetypeinterfacenumber[ip
address]}[dhcp][distance][namenexthopname][permanent|tracknumber][tag
tag]
62
Verifying IP SLAs
Command
show ip sla
configuration
[operation]
show ip sla statistics
[operation-number |
details]
Description
Display configuration values including all defaults for all
Cisco IOS IP SLAs operations, or for a specified operation.
The operation parameter is the number of the IP SLAs
operation for which the details will be displayed.
Display the current operational status and statistics of all
Cisco IOS IP SLAs operations, or of a specified operation.
Note:
Effective with Cisco IOS Release 12.4(20)T, 12.2(33)SXI1, 12.2(33)SRE and Cisco IOS
XE Release 2.4, the show ip sla monitor configuration command is
replaced by the show ip sla configuration command.
Note:
Effective with Cisco IOS Release 12.4(20)T, 12.2(33)SXI1, 12.2(33)SRE and Cisco IOS
XE Release 2.4, the show ip sla monitor statisitcs command is replaced
by the show ip sla statistics command.
R1(config)# ip sla 11
R1(config-ip-sla)# icmp-echo 10.1.3.3
R1(config-ip-sla-echo)# frequency 10
R1(config-ip-sla-echo)# exit
R1(config)# ip sla schedule 11 life forever start-time now
R1(config)# track 1 ip sla 11 reachability
R1(config-track)# delay down 10 up 1
R1(config-track)# exit
R1(config)# ip route 0.0.0.0 0.0.0.0 10.1.1.1 2 track 1
R1(config)# ip route 0.0.0.0 0.0.0.0 172.16.1.1 3
Probe
The second step defines the tracking object, which is linked to the probe from the first
step.
The track 1 ip sla 11 reachability command specifies that object 1 is tracked; it is
linked to probe 11 (defined in the first step) so that the reachability of the 10.1.3.3 is
tracked.
R1(config)# ip sla 11
R1(config-ip-sla)# icmp-echo 10.1.3.3
R1(config-ip-sla-echo)# frequency 10
R1(config-ip-sla-echo)# exit
R1(config)# ip sla schedule 11 life forever start-time now
R1(config)# track 1 ip sla 11 reachability
R1(config-track)# delay down 10 up 1
R1(config-track)# exit
R1(config)# ip route 0.0.0.0 0.0.0.0 10.1.1.1 2 track 1
R1(config)# ip route 0.0.0.0 0.0.0.0 172.16.1.1 3
Probe
Tracking
Object
The last step defines an action based on the status of the tracking object.
The ip route 0.0.0.0 0.0.0.0 10.1.1.1 2 track 1 command conditionally configures
the default route, via 10.1.1.1, with an administrative distance of 2, if the result of
tracking object 1 is true.
Thus, if 10.1.3.3 is reachable, a static default route via 10.1.1.1 with an administrative
distance of 2, is installed in the routing table.
R1(config)# ip sla 11
R1(config-ip-sla)# icmp-echo 10.1.3.3
R1(config-ip-sla-echo)# frequency 10
R1(config-ip-sla-echo)# exit
R1(config)# ip sla schedule 11 life forever start-time now
R1(config)# track 1 ip sla 11 reachability
R1(config-track)# delay down 10 up 1
R1(config-track)# exit
R1(config)# ip route 0.0.0.0 0.0.0.0 10.1.1.1 2 track 1
R1(config)# ip route 0.0.0.0 0.0.0.0 172.16.1.1 3
Probe
Tracking
Object
Status of Tracking Object
R1(config)# ip sla 11
R1(config-ip-sla)# icmp-echo 10.1.3.3
Probe
R1(config-ip-sla-echo)# frequency 10
R1(config-ip-sla-echo)# exit
R1(config)# ip sla schedule 11 life forever start-time now
R1(config)# track 1 ip sla 11 reachability
R1(config-track)# delay down 10 up 1
Tracking
R1(config-track)# exit
Object
R1(config)# ip route 0.0.0.0 0.0.0.0 10.1.1.1 2 track 1
Status of Tracking Object
R1(config)# ip route 0.0.0.0 0.0.0.0 172.16.1.1 3
If 10.1.1.1 is reachable, a static default route via R2 with an administrative distance of 2, is installed
in the routing table
If 172.16.1.1 is reachable, a static default route via R3 with an administrative distance of 3 is
available to the routing table as a backup path.
R1(config)# ip sla 11
R1(config-ip-sla)# icmp-echo 10.1.3.3
Probe
R1(config-ip-sla-echo)# frequency 10
R1(config-ip-sla-echo)# exit
R1(config)# ip sla schedule 11 life forever start-time now
R1(config)# track 1 ip sla 11 reachability
R1(config-track)# delay down 10 up 1
Tracking
R1(config-track)# exit
Object
R1(config)# ip route 0.0.0.0 0.0.0.0 10.1.1.1 2 track 1
Status of Tracking Object
R1(config)# ip route 0.0.0.0 0.0.0.0 172.16.1.1 3
IP SLA 11 continuously sends ICMP Echo Requests to the DNS server (10.1.3.3) every 10
seconds.
IP SLAs is tracking that object and as long as the DNS server is reachable, the default route
to R2 will be in the routing table.
R1(config)# ip sla 11
R1(config-ip-sla)# icmp-echo 10.1.3.3
R1(config-ip-sla-echo)# frequency 10
R1(config-ip-sla-echo)# exit
R1(config)# ip sla schedule 11 life forever start-time now
R1(config)# track 1 ip sla 11 reachability
R1(config-track)# delay down 10 up 1
R1(config-track)# exit
R1(config)# ip route 0.0.0.0 0.0.0.0 10.1.1.1 2 track 1
R1(config)# ip route 0.0.0.0 0.0.0.0 172.16.1.1 3
Configuring PBR
and IP SLA
Example
76
77
Stats
Return Last
(ms)
Code
Run
*1
icmpecho
10.10.30.2
RTT=1
OK
1secondago
BR1#
79