# bridge: attempt only the defined interface
if [ -e /tmp/bridge.info ]; then
. /tmp/bridge.info
- IFACES="$IFACES ${bridgeslaves%% *}"
+ RAW_IFACES="$RAW_IFACES $bridgeslaves"
MASTER_IFACES="$MASTER_IFACES $bridgename"
fi
unset bondname
. "$i"
# It is enough to fire up only one
- IFACES="$IFACES ${bondslaves%% *}"
+ RAW_IFACES="$RAW_IFACES $bondslaves"
MASTER_IFACES="$MASTER_IFACES ${bondname}"
done
unset teamslaves
unset teammaster
. "$i"
- IFACES="$IFACES ${teamslaves}"
+ RAW_IFACES="$RAW_IFACES ${teamslaves}"
MASTER_IFACES="$MASTER_IFACES ${teammaster}"
done
if [ -e /tmp/vlan.info ]; then
. /tmp/vlan.info
- IFACES="$IFACES $phydevice"
+ RAW_IFACES="$RAW_IFACES $phydevice"
MASTER_IFACES="$MASTER_IFACES ${vlanname}"
fi
+ MASTER_IFACES="$(trim "$MASTER_IFACES")"
+ RAW_IFACES="$(trim "$RAW_IFACES")"
if [ -z "$IFACES" ]; then
[ -e /tmp/net.ifaces ] && read IFACES < /tmp/net.ifaces
runcmd="RUN+=\"/sbin/initqueue --name ifup-\$env{INTERFACE} --unique --onetime $ifup\""
# We have some specific interfaces to handle
- if [ -n "$IFACES" ]; then
+ if [ -n "${RAW_IFACES}${IFACES}" ]; then
echo 'SUBSYSTEM!="net", GOTO="net_end"'
echo 'ACTION!="add|change|move", GOTO="net_end"'
- for iface in $IFACES; do
+ for iface in $IFACES $RAW_IFACES; do
case "$iface" in
??:??:??:??:??:??) # MAC address
cond="ATTR{address}==\"$iface\""
done
echo 'LABEL="net_end"'
- if [ -n "$MASTER_IFACES" ]; then
- wait_ifaces=$MASTER_IFACES
- else
- wait_ifaces=$IFACES
- fi
-
- for iface in $wait_ifaces; do
+ for iface in $IFACES; do
if [ "$bootdev" = "$iface" ] || [ "$NEEDNET" = "1" ]; then
echo "[ -f /tmp/net.${iface}.did-setup ]" >$hookdir/initqueue/finished/wait-$iface.sh
fi