diff options
author | Stephen Hemminger <stephen.hemminger@vyatta.com> | 2009-12-22 14:41:31 -0800 |
---|---|---|
committer | Stephen Hemminger <stephen.hemminger@vyatta.com> | 2009-12-22 14:51:32 -0800 |
commit | d350f1500cde8c14a4e4bb627da4723c06840cb2 (patch) | |
tree | ff479ff10ebcb0e054252796a1657c6c5883423e /scripts | |
parent | 58dbee10b4dfa1c2cf6a644e7818983c296a96fb (diff) | |
download | vyatta-cfg-system-d350f1500cde8c14a4e4bb627da4723c06840cb2.tar.gz vyatta-cfg-system-d350f1500cde8c14a4e4bb627da4723c06840cb2.zip |
Bring device to up state when removed from bond
Bug 5061
Force device back to up state when leaving bond group.
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/vyatta-bonding.pl | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/scripts/vyatta-bonding.pl b/scripts/vyatta-bonding.pl index 3012c5f9..3ecffdda 100755 --- a/scripts/vyatta-bonding.pl +++ b/scripts/vyatta-bonding.pl @@ -170,6 +170,13 @@ sub add_port { add_slave ($intf, $slave); } +sub remove_port { + my ( $intf, $slave ) = @_; + + remove_slave ($intf, $slave); + if_up ($slave); +} + sub usage { print "Usage: $0 --dev=bondX --mode={mode}\n"; print " $0 --dev=bondX --add=ethX\n"; @@ -192,4 +199,4 @@ die "$0: device not specified\n" unless $dev; change_mode( $dev, $mode ) if $mode; add_port( $dev, $add_port ) if $add_port; -remove_slave( $dev, $rem_port ) if $rem_port; +remove_port( $dev, $rem_port ) if $rem_port; |