From 80e0627acce79cef9df7d7b35fe436e70bdb0d65 Mon Sep 17 00:00:00 2001 From: Vladyslav Morokhovych Date: Fri, 13 Aug 2021 09:25:28 +0300 Subject: [PATCH] [swss] Fix arp_update script (#8412) Fix #7968 Issue is detected on SONiC.20201231.11 In test_static_route.py::test_static_route_ecmp static routes are configured, but neighbors are not resolved after config reload even after 10 minutes. It looks like the arp_update script is starting to ping when Vlan1000 is not fully configured. When issue is reproduced, stuck ping6 process is observed in swss container : USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND root 180 0.1 0.0 6296 1272 pts/0 S 17:03 0:03 ping6 -I Vlan1000 -n -q -i 0 -c 1 -W 0 ff02::1 And when arp_update script successfully resolves neighbors, we observe sleep 300 instead of ping process --- files/scripts/arp_update | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/files/scripts/arp_update b/files/scripts/arp_update index 1d4cf1ec541f..e7f083e20d27 100755 --- a/files/scripts/arp_update +++ b/files/scripts/arp_update @@ -37,7 +37,7 @@ while /bin/true; do eval `eval $ipcmd` # send ipv6 multicast pings to Vlan interfaces to get/refresh link-local addrs - ping6cmd="ping6 -I $vlan -n -q -i 0 -c 1 -W 0 ff02::1 >/dev/null" + ping6cmd="timeout 1 ping6 -I $vlan -n -q -i 0 -c 1 -W 0 ff02::1 >/dev/null" eval $ping6cmd # generate a list of ndisc6 commands (exclude link-local addrs since it is done above):