Pages

Saturday 13 May 2023

Enhanced Object Tracking

Enhanced Object Tracking (SLA Track)

Enhanced Object tracking allows you to track specific objects on the device, such as the interface line protocol state, IP routing, route reachability, and to take action when the tracked object's state changes. This feature allows you to increase the availability of the network and shorten recovery time if an object state goes down.

The Enhanced Object Tracking feature provides complete separation between the objects to be tracked and the action to be taken by a client when a tracked object changes. Thus, several clients such as HSRP, VRRP, or GLPB can register their interest with the tracking process, track the same object. Each client is notified when the tracking object changes state, and each can take different action when the object changes. Each tracked object is identified by a unique number that is specified on the tracking CLI. Client processes use this number to track a specific object. The tracking process periodically polls the tracked objects and notes any change of value. The changes in the tracked object are communicated to interested client processes, either immediately or after a specified delay. The object values are reported as either up or down

An object monitors the statistics and state of the IP SLA instance and performs an action based on the status of the probe. This can be used for HSRP, VRRP to change priority levels.

You can configure a combination of tracked objects in a list and a flexible method for combining objects using Boolean logic. This functionality includes the following capabilities:

  • Threshold: The tracked list can be configured to use a weight or percentage threshold to measure the state of the list. Each object in a tracked list can be assigned a threshold weight. The state of the tracked list is determined by whether the threshold has been met.
  • Boolean "and" function: When a tracked list has been assigned a Boolean "and" function, each object defined within a subset must be in an up state so that the tracked object can become up.
  • Boolean "or" function: When the tracked list has been assigned a Boolean "or" function, at least one object defined within a subset must be in an up state so that the tracked object can become up.

Enhanced Tracking Object (ETO) can be used to track a variety of objects including:

  • Interface line-protocol state
  • IP address
  • MAC address
  • Hostname
  • SNMP OID

ETO can be used to improve the performance and reliability of a variety of Cisco IOS features, including:

  • HSRP
  • VRRP
  • GLBP
  • PIM
  • OSPF
  • BGP

IP SLA Tracking

Enhanced Object Tracking can be used to track the status of an IP SLA; state or reachability.

To configure a tracking object:
  1. Create an IP SLA probe:

    R1(config)#ip sla 100
    R1(config-ip-sla)#icmp-echo 192.168.12.2
    R1(config-ip-sla-echo)#frequency 10
    R1(config-ip-sla-echo)#exit
    R1(config)#ip sla schedule 100 start-time now life forever

    Read more on details of the creation of IP SLA.

  2. Set up a tracking object based on that probe: Reference the IP SLA that will be tracked by the tracking object using the command track <obj-num> ip sla <sla-num> [state | reachability]. When configuring a tracking object, a boolean operation AND or OR can be specified where the results of a series of tracking objects can be compared.

    R1(config)#track 100 ip sla 100 reachability

  3. Configure a delay on the object to regulate the flapping of the object using the command delay [down <seconds> | up <seconds>].

    R1(config-track)#delay down 3 up 3

  4. Associate the tracking object with a client process. In the following subsection, the tracking object is associated with a static route.

IP SLA tracking can be leveraged to improve the efficiency and reliability of static routing, dynamic routing using OSPF, BGP.

Static Route Tracking

IP SLAs can be used in combination with static routes. IP SLA can be used to install or remove a static route from the Routing Information Base (RIB) only if certain conditions are met. A tracking object needs to be defined to track the results of the probe and implement an action.

Note: When installing a tracked static route, install the tracked static route after configuring the non-tracked static route.

R1(config)#track 100 ip sla 100
R1(config-track)#delay down 3 up 0
R1(config-track)#exit
R1(config)#ip route 4.4.4.4 255.255.255.255 192.168.13.2 10
R1(config)#ip route 4.4.4.4 255.255.255.255 192.168.12.2 track 100

Verification

show track <obj-num>

Verify a tracked object.

R1#show track
Track 100
  IP SLA 100 reachability
  Reachability is Down
    4 changes, last change 00:00:19
  Delay up 3 secs, down 3 secs
  Latest operation return code: Timeout
  Tracked by:
    STATIC-IP-ROUTING 0

show ip route

A tracked static route can be verified using the command show ip route.

R1#
*May 13 05:44:11.479: %TRACKING-5-STATE: 100 ip sla 100 reachability Up->Down
R1#show ip route                                                
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area  
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2  
       E1 - OSPF external type 1, E2 - OSPF external type 2            
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
       + - replicated route, % - next hop override                    
                                                                      
Gateway of last resort is 192.168.13.2 to network 0.0.0.0              
                                                                      
S*    0.0.0.0/0 [10/0] via 192.168.13.2                                
      192.168.12.0/24 is variably subnetted, 2 subnets, 2 masks        
C        192.168.12.0/30 is directly connected, GigabitEthernet0/0    
L        192.168.12.1/32 is directly connected, GigabitEthernet0/0    
      192.168.13.0/24 is variably subnetted, 2 subnets, 2 masks        
C        192.168.13.0/30 is directly connected, GigabitEthernet1/0    
L        192.168.13.1/32 is directly connected, GigabitEthernet1/0    
      192.168.24.0/30 is subnetted, 1 subnets                          
D        192.168.24.0 [90/3328] via 192.168.13.2, 00:00:19, GigabitEthernet1/0
      192.168.34.0/30 is subnetted, 1 subnets                          
D        192.168.34.0 [90/3072] via 192.168.13.2, 00:12:18, GigabitEthernet1/0
*May 13 05:45:33.479: Track: 100 Up change delayed for 3 secs          
R1#                                                                    
*May 13 05:45:36.479: Track: 100 Up change delay expired              
*May 13 05:45:36.479: Track: 100 Change #5 ip sla 100, reachability Down->Up
R1#                                                                    
*May 13 05:45:36.483: %TRACKING-5-STATE: 100 ip sla 100 reachability Down->Up
R1#show ip route                                                
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area  
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2  
       E1 - OSPF external type 1, E2 - OSPF external type 2            
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
       + - replicated route, % - next hop override                    
                                                                      
Gateway of last resort is 192.168.12.2 to network 0.0.0.0              
                                                                      
S*    0.0.0.0/0 [1/0] via 192.168.12.2                                
      192.168.12.0/24 is variably subnetted, 2 subnets, 2 masks        
C        192.168.12.0/30 is directly connected, GigabitEthernet0/0    
L        192.168.12.1/32 is directly connected, GigabitEthernet0/0    
      192.168.13.0/24 is variably subnetted, 2 subnets, 2 masks        
C        192.168.13.0/30 is directly connected, GigabitEthernet1/0    
L        192.168.13.1/32 is directly connected, GigabitEthernet1/0    
      192.168.24.0/30 is subnetted, 1 subnets                          
D        192.168.24.0 [90/3072] via 192.168.12.2, 00:23:48, GigabitEthernet0/0
      192.168.34.0/30 is subnetted, 1 subnets                          
D        192.168.34.0 [90/3072] via 192.168.13.2, 00:23:44, GigabitEthernet1/0

debug track <all>

R1#debug track
Track debugging is on
R1#
*May 13 05:45:33.479: Track: 100 Up change delayed for 3 secs
R1#
*May 13 05:45:36.479: Track: 100 Up change delay expired
*May 13 05:45:36.479: Track: 100 Change #5 ip sla 100, reachability Down->Up
R1#
*May 13 05:45:36.483: %TRACKING-5-STATE: 100 ip sla 100 reachability Down->Up

Interface State Tracking

Enhanced tracking objects can be used to monitor the state of an interface. This is implemented using the command track interface ip routing. This enables the tracking of the following states on an interface:

  • line protocol
  • IP address
  • IP routing: ability of an interface to route packets
If the line protocols is down, interface has no IP address, or IP routing is disabled, then the tracking object will consider the interface state to be down. The enhanced object track supports the assignment of an IP address to an interface through any of the following methods:
  • PPP/IPCP
  • DHCP
  • Conventional IP address configuration
  • Unnumbered interface

Enhanced object tracking of the state of an interface can be enabled by the following steps:

  1. Create a tracking list to track the state of the interface:
    • line-protocol: using the command track <obj-num> interface <interface-id> line-protocol.

      R4(config)#track 200 interface gigabitethernet1/0 line-protocol

    • ip routing: tracks an IP route in the routing table and the ability of an interface to route IP packets. track <obj-num> interface <interface-id> ip routing.
  2. Configure the delay period using command delay up <1-180> down <1-180>. The delay value is in seconds.

    R4(config-track)#delay down 0 up 3

  3. (Optional) Let the tracking object consider the carrier delay timer when tracking the interface status: carrier delay.
  4. (Optional) Configure the interval in which the tracking process polls the tracked object using the command track timer interface [<seconds > | msec <milliseconds>] . The default interval is 1 second. The msec keyword sets the interval down to milliseconds.

Tracking IP Route Reachability

Tracks the reachability of an IP route. A tracked object is considered up when a routing table entry exists for the route and the route is accessible.

  1. Configure the tracking object: track <obj-num> ip route <ip-address/prefix-length> reachability.
  2. Specify the delay values delay up <seconds> down <seconds>
  3. (Optional) Specify the VRF: ip vrf <vrf>.

Verification

show ip route track-table

Displays information about the IP route track table.

R1#show ip route track-table
  ip route 0.0.0.0 0.0.0.0 192.168.12.2 track 100 state is [up]
R1#

show track [object-number ]

Displays information about the all tracking lists or the specified list.

R4#show track 200
Track 200
  Interface GigabitEthernet1/0 line-protocol
  Line protocol is Up
    3 changes, last change 00:00:05
  Delay up 3 secs
  Tracked by:
    STATIC-IP-ROUTING 0

show track brief

Displays a single line of tracking information output.

R1#show track brief
Track   Object                           Parameter        Value Last Change
100     ip sla      100                  reachability     Up    00:31:10  
R1#

show track interface [brief]

Displays information about tracked interface objects.

R4#show track interface brief
Track   Object                           Parameter        Value Last Change
200     interface   GigabitEthernet1/0   line-protocol    Down  00:00:24
R4#show track interface
Track 200      
  Interface GigabitEthernet1/0 line-protocol
  Line protocol is Down (hw admin-down)
    2 changes, last change 00:00:29
  Delay up 3 secs
  Tracked by:  
    STATIC-IP-ROUTING 0 R4#

show track ip [object-number ] [brief ] route

Displays information about tracked IP-route objects.

show track resolution

Displays the resolution of tracked parameters.

R1#sho track resolution
Route type     Metric Resolution
static         10  
EIGRP          2560
OSPF           1  
ISIS           10  
BGP            2560

show track timers

Displays tracked polling interval timers.

R1#show track timers
Object type   Poll Interval Time to next poll
interface     1             expired
ip route      15            expired
ip sla        5             3.716  
application   5             expired
list          1             expired
stub          1             expired

No comments: