From: Harald Hoyer Date: Mon, 7 Aug 2017 13:09:13 +0000 (+0200) Subject: network/ifup: don't arping for point-to-point connections X-Git-Tag: 046~6 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5abd692fe46215c38f564b59db50193daf745af5;p=thirdparty%2Fdracut.git network/ifup: don't arping for point-to-point connections https://bugzilla.redhat.com/show_bug.cgi?id=1477339 --- diff --git a/modules.d/40network/ifup.sh b/modules.d/40network/ifup.sh index f979b59bc..687b5707f 100755 --- a/modules.d/40network/ifup.sh +++ b/modules.d/40network/ifup.sh @@ -113,15 +113,17 @@ do_static() { echo 1 > /proc/sys/net/ipv6/conf/$netif/accept_redirects wait_for_ipv6_dad $netif else - if command -v arping2 >/dev/null; then - if arping2 -q -C 1 -c 2 -I $netif -0 $ip ; then - warn "Duplicate address detected for $ip for interface $netif." - return 1 - fi - else - if ! arping -f -q -D -c 2 -I $netif $ip ; then - warn "Duplicate address detected for $ip for interface $netif." - return 1 + if [ -z "$srv" ]; then + if command -v arping2 >/dev/null; then + if arping2 -q -C 1 -c 2 -I $netif -0 $ip ; then + warn "Duplicate address detected for $ip for interface $netif." + return 1 + fi + else + if ! arping -f -q -D -c 2 -I $netif $ip ; then + warn "Duplicate address detected for $ip for interface $netif." + return 1 + fi fi fi ip addr flush dev $netif