From 47cb618f6fc33ffa62bdc77e87166e631dc8576f Mon Sep 17 00:00:00 2001 From: Lawrence Lee Date: Wed, 10 Jan 2024 14:40:15 -0800 Subject: [PATCH] add timeout to ping6 command (#17729) Signed-off-by: Lawrence Lee --- 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 14a82ebe4d..9926c417b3 100755 --- a/files/scripts/arp_update +++ b/files/scripts/arp_update @@ -63,7 +63,7 @@ while /bin/true; do ALL_INTERFACE="$INTERFACE $PC_INTERFACE $VLAN_SUB_INTERFACE" for intf in $ALL_INTERFACE; do - ping6cmd="ping6 -I $intf -n -q -i 0 -c 1 -W 0 ff02::1 >/dev/null" + ping6cmd="timeout 0.2 ping6 -I $intf -n -q -i 0 -c 1 -W 0 ff02::1 >/dev/null" intf_up=$(ip link show $intf | grep "state UP") if [[ -n "$intf_up" ]]; then eval $ping6cmd