always mark the interface as 'up' last

since that kinda acts as a marker that everything is ready
This commit is contained in:
Matthias Radestock committed 2014-11-27 09:56:12 +00:00
1 parent 8fac46a429
commit d9ea3b44a1
1 file changed
+4 -4
+4 -4
View File
@@ -216,8 +216,8 @@ connect_container_to_bridge() {
launch() { launch() {
connect_container_to_bridge && connect_container_to_bridge &&
ip netns exec $NETNS ip link set $CONTAINER_IFNAME up && check_command_and_run_anything ethtool ip netns exec $NETNS ethtool -K eth0 tx off >/dev/null &&
check_command_and_run_anything ethtool ip netns exec $NETNS ethtool -K eth0 tx off >/dev/null ip netns exec $NETNS ip link set $CONTAINER_IFNAME up
} }
attach() { attach() {
@@ -237,9 +237,9 @@ attach() {
fi fi
if ! connect_container_to_bridge || if ! connect_container_to_bridge ||
! check_command_and_run_anything ethtool ip netns exec $NETNS ethtool -K $CONTAINER_IFNAME tx off >/dev/null ||
! ip netns exec $NETNS ip addr add $1 dev $CONTAINER_IFNAME || ! ip netns exec $NETNS ip addr add $1 dev $CONTAINER_IFNAME ||
! ip netns exec $NETNS ip link set $CONTAINER_IFNAME up || ! ip netns exec $NETNS ip link set $CONTAINER_IFNAME up ; then
! check_command_and_run_anything ethtool ip netns exec $NETNS ethtool -K $CONTAINER_IFNAME tx off >/dev/null ; then
return 1 return 1
fi fi