Configuration Guide
Reliability Configuration
TRACK and SLA Configuration
12 min
track and sla configuration track and sla configuration introduction introduction track in order to further improve network reliability, redundancy protection methods are commonly used in practice, where two devices backup each other and can also share the workload when one of the devices experiences a link failure, the other device can take over to continue forwarding user traffic this results in a situation where a device accesses both primary and backup devices this also creates issues of link reliability and load balancing between devices when part or all of the network side links fail, the bandwidth of these links decreases, and the access side may not immediately detect the occurrence of this failure, leading to network congestion or loss of traffic therefore, by configuring track monitoring groups, routes can be withdrawn promptly after a link failure to prevent traffic from being forwarded through the failed link sla link quality metrics serve as criteria for judging whether the links of intelligent route selection member meet quality requirements when health checks and link quality metrics are referenced in global route selection policies or multi exit policy routing, the device continuously checks whether the quality of interface links (delay, jitter, and packet loss rate) meets the quality requirements specified by the link quality metrics links that do not meet the requirements do not participate in intelligent route selection until the link quality meets the requirements again explanation of principles explanation of principles the network administrator configures static routes on the router, instructing the switch how to forward packets to the destination network additionally, the administrator configures route monitoring groups after configuring the route monitoring group, the device actively sends icmp request packets to the specified ip address based on network performance and packet loss rate information, it determines whether the ip address is reachable when the target address is unreachable, the device proactively withdraws the statically configured route, enabling fault tolerance in the network and ensuring high availability and stability track and sla configuration track and sla configuration configure tasks instructions create an sla instance required create a track route monitoring instance required bind the sla instance to the track route monitoring instance required creating an sla instance creating an sla instance operation command description enter the system configuration view configure terminal create an sla instance sla id icmp echo dst ip a b c d | a b \[src port ethernet | lag | vlan ] \[timeout time ] \[frequency time ] dst ip :specify the destination ip address src port :set the source port for sending probes timeout :probe timeout wait time range 1 3600 seconds, default value is 5 frequency :probe packet sending interval, range 1 3600 seconds, default value is 5 creating a track route monitoring instance creating a track route monitoring instance create a track monitoring instance and bind it with a static route and sla instance when the destination ip address probed by sla is unreachable, use the track to notify the static route to delete, ensuring that packets are no longer forwarded through that route when the probing result of sla is restored, the static route is automatically restored operation command description enter the system configuration view configure terminal create a track route monitoring instance track id add monitored routers to the route monitoring group route a b c d/m a b c d \[ vrf name ] binding the sla instance to the track route monitoring instance binding the sla instance to the track route monitoring instance operation command description enter track configuration view track id binding the sla instance sla id display and maintenance display and maintenance operation command display track instance info show track brief display sla info show sla brief configuration example configuration example network requirements in the network topology, switches use static routes for packet forwarding, and on switch1 and switch4, equal cost multi path (ecmp) is configured, with the next hops being switch2 and switch3 respectively when there is a link failure on either switch2 or switch3, switch1 and switch4 can promptly detect the link failure using track and sla functionalities, and quickly converge the routes procedure the configuration process for interconnecting ip addresses between devices is omitted here configuration on switch 1 \# configure sla sonic(config)# sla 1 icmp echo dst ip 10 1 1 2 src port ethernet 21 sonic(config)# sla 2 icmp echo dst ip 20 1 1 2 src port ethernet 22 \# configure track sonic(config)# track 1 sonic(config track 1)# sla 1 sonic(config track 1)# route 150 1 0 1/24 10 1 1 2 sonic(config)# track 2 sonic(config track 2)# sla 2 sonic(config track 2)# route 150 1 0 1/24 20 1 1 2 verify configuration display sla and track configuration sonic(config)# do show sla brief \===================================icmp echo==================================== sla id type dst ip min time avg time max time packt loss \ 1 icmp echo 10 1 1 2 0 772 1 089 1 431 0% 2 icmp echo 20 1 1 2 0 849 1 128 1 446 0% sonic(config)# do show track brief track id bind sla id state \ 1 1 success 2 2 success display the route info on switch1 sonic(config)# do show ip route codes k kernel route, c connected, s static, r rip, o ospf, i is is, b bgp, e eigrp, n nhrp, t table, v vnc, v vnc direct, a babel, f pbr, f openfabric, \\> selected route, fib route, q queued, r rejected, b backup t trapped, o offload failure s> 150 1 0 0/24 \[1/0] via 10 1 1 2, ethernet21, weight 1, 00 00 14 \\ via 20 1 1 2, ethernet22, weight 1, 00 00 14 when the link between switch 1, switch 2, and switch 4 encounters an obstacle, and sla1 detects a packet loss rate of 100%, the route from switch 2 to switch 4 on switch 1 will be withdrawn sonic(config)# do show sla brief \===================================icmp echo==================================== sla id type dst ip min time avg time max time packt loss \ 1 icmp echo 10 1 1 2 0 0 0 100% 2 icmp echo 20 1 1 2 0 729 1 273 1 673 0% sonic(config)# do show track brief track id bind sla id state \ 1 1 failure 2 2 success sonic(config)# do show ip route codes k kernel route, c connected, s static, r rip, o ospf, i is is, b bgp, e eigrp, n nhrp, t table, v vnc, v vnc direct, a babel, f pbr, f openfabric, \\> selected route, fib route, q queued, r rejected, b backup t trapped, o offload failure s> 150 1 0 0/24 \[1/0] via 20 1 1 2, ethernet22, weight 1, 00 00 51
