Package: ifenslave-2.6 Version: 1.1.0-8 Severity: normal
The current pre-up script will not enslave any interface which has already been brought up by ifupdown. This breaks some configurations, such as when wpasupplicant is being used via it's ifupdown integration for a wireless interface that is being slaved with a wired interface. In such a configuration, the wireless interface must be "ifup'd" before it can be enslaved to the bonding device. A simple fix for this is for the pre-up script to only refuse to enslave interfaces chosen by "slaves auto", and to honour explicit device listings (such as "slave eth0 wlan0"). The attached patch implements this fix. -- System Information: Debian Release: lenny/sid APT prefers testing APT policy: (500, 'testing'), (500, 'stable') Architecture: i386 (i686) Kernel: Linux 2.6.24-1-686 (SMP w/2 CPU cores) Locale: LANG=C, LC_CTYPE=en_CA.iso8859-1 (charmap=ISO-8859-1) Shell: /bin/sh linked to /bin/bash Versions of packages ifenslave-2.6 depends on: ii libc6 2.7-6 GNU C Library: Shared libraries Versions of packages ifenslave-2.6 recommends: ii net-tools 1.60-19 The NET-3 networking toolkit -- no debconf information
--- ifenslave-2.6-1.1.0/debian/pre-up 2008-03-19 16:20:33.000000000 -0600 +++ /etc/network/if-pre-up.d/ifenslave 2008-03-19 16:21:54.000000000 -0600 @@ -30,6 +30,7 @@ ;; all) INTERFACES=`grep eth /proc/net/dev|sed 's/\(\ *\)\(eth[^:]*\)\(.*\)/\2/'` + AUTOIF="yes" ;; *) INTERFACES="$IF_SLAVES" @@ -66,7 +67,7 @@ fi ifconfig "$IFACE" up for slave in $INTERFACES ; do - if grep -q "^$slave=" $IFSTATE ; then + if ( [ "$AUTOIF" ] && grep -q "^$slave=" $IFSTATE ) ; then echo "Not enslaving interface $slave since it is already configured" else ifconfig "$slave" down