mirror of
https://github.com/samba-team/samba.git
synced 2025-01-11 05:18:09 +03:00
during startup make sure to delete any public addresses from any
interface (This used to be ctdb commit 18d80ea6db39e61f60e4c01de164d58bcbd8ab10)
This commit is contained in:
parent
6052078b53
commit
8edcd3f83f
@ -66,6 +66,15 @@ case $cmd in
|
|||||||
[ -f /proc/sys/net/ipv4/conf/all/arp_filter ] && {
|
[ -f /proc/sys/net/ipv4/conf/all/arp_filter ] && {
|
||||||
echo 1 > /proc/sys/net/ipv4/conf/all/arp_filter
|
echo 1 > /proc/sys/net/ipv4/conf/all/arp_filter
|
||||||
}
|
}
|
||||||
|
cat "$CTDB_PUBLIC_ADDRESSES" | cut -d/ -f1 | while read _IP; do
|
||||||
|
_IP_HELD=`ip addr show | grep "inet $_IP/"`
|
||||||
|
[ -z "$_IP_HELD" ] || {
|
||||||
|
_IFACE=`echo $_IP_HELD | sed -e "s/.*\s//"`
|
||||||
|
_NM=`echo $_IP_HELD | sed -e "s/.*$_IP\///" -e "s/\s.*//"`
|
||||||
|
echo Removing public address "$_IP"/"$_NM" from device "$_IFACE"
|
||||||
|
ip addr del $_IP/$_NM dev $_IFACE >/dev/null 2>&1
|
||||||
|
}
|
||||||
|
done
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user