Package: ifenslave Version: 2.12 Severity: important Tags: patch The if-post-down hook does not delete the bonding interface. Therefore e.g. „ifdown -a; ifup -a“ does not work without manually removing it using „ip link dev“ or „rmmod bonding“ in between.
The attached patch should fix that.
diff --git a/debian/ifenslave.if-post-down b/debian/ifenslave.if-post-down index 0113fd4..177a06c 100755 --- a/debian/ifenslave.if-post-down +++ b/debian/ifenslave.if-post-down @@ -56,10 +56,13 @@ sysfs_remove_all arp_ip_target read -r slaves < "$BOND_PARAMS/slaves" for slave in $slaves ; do # This is supposed to have the side effect of freeing the interface. - ifquery --state "$slave" && ifdown $v "$slave" + ifquery --state "$slave" >/dev/null 2>&1 && ifdown $v "$slave" # Anyway, ensure $slave is free. if [ -f "/sys/class/net/$slave/master/bonding/slaves" ] ; then echo "-$slave" > "$BOND_PARAMS/slaves" 2> /dev/null fi done + +# Delete the bond interface +ip link del dev "$IFACE"