From fafd0d2a6ea0de699948a22fd3ca603f7036c1f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E5=87=AF=E9=BE=99?= Date: Wed, 6 Nov 2024 10:58:08 +0800 Subject: [PATCH] [bugfix] When add_eip, send an ARP packet from net1 to the gateway to announce the EIP to the switch. --- dist/images/vpcnatgateway/nat-gateway.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/dist/images/vpcnatgateway/nat-gateway.sh b/dist/images/vpcnatgateway/nat-gateway.sh index 83860912df2..3235923113b 100644 --- a/dist/images/vpcnatgateway/nat-gateway.sh +++ b/dist/images/vpcnatgateway/nat-gateway.sh @@ -144,6 +144,7 @@ function add_eip() { exec_cmd "ip route replace default via $gateway dev net1" ip route | grep "default via $gateway dev net1" exec_cmd "arping -I net1 -c 3 -D $eip_without_prefix" + exec_cmd "arping -I net1 -c 1 -s $eip_without_prefix $gateway" done }