summaryrefslogtreecommitdiff
path: root/python/vyos/ifconfig/bond.py
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2020-03-28 12:06:41 +0100
committerChristian Poessinger <christian@poessinger.com>2020-03-28 12:06:41 +0100
commit792c00a018d0b237996e60845edf8ad970c4afbb (patch)
tree15bea8859399c540db517c46bd78e75a5e005e78 /python/vyos/ifconfig/bond.py
parenta0424f9c6a4cf813934d5a3bc877fddae6eb99de (diff)
parent822e171a0023c3f8f335cda08bcbf70b2d6d4070 (diff)
downloadvyos-1x-792c00a018d0b237996e60845edf8ad970c4afbb.tar.gz
vyos-1x-792c00a018d0b237996e60845edf8ad970c4afbb.zip
Merge branch 't1831-ipv6' into current
* t1831-ipv6: ipv6: T1831: migrate eui64 addressing to XML and python vyos.util: import cleanup ipv6: T1831: migrate autoconf node ipv6: T1831: use integers over bool in interface configuration ipv6: T1831: migrate forwarding and dup-addr-detect-transmits nodes ipv6: T1831: Makefile: remove node.def files in ipv6 folder ifconfig: T2057: explicity name state functions ifconfig: T2167: get_mac was not returning ifconfig: T2057: add get_alias function ifconfig: T2057: option forcing merge config: T2169: remove redundant use of show_config
Diffstat (limited to 'python/vyos/ifconfig/bond.py')
-rw-r--r--python/vyos/ifconfig/bond.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/python/vyos/ifconfig/bond.py b/python/vyos/ifconfig/bond.py
index 3c26b9b95..e2ff71490 100644
--- a/python/vyos/ifconfig/bond.py
+++ b/python/vyos/ifconfig/bond.py
@@ -101,7 +101,7 @@ class BondIf(Interface):
for s in self.get_slaves():
slave = {
'ifname': s,
- 'state': Interface(s).get_state()
+ 'state': Interface(s).get_admin_state()
}
slave_list.append(slave)
@@ -112,7 +112,7 @@ class BondIf(Interface):
# physical interface
for slave in slave_list:
i = Interface(slave['ifname'])
- i.set_state(slave['state'])
+ i.set_admin_state(slave['state'])
def set_hash_policy(self, mode):
"""
@@ -211,7 +211,7 @@ class BondIf(Interface):
# An interface can only be added to a bond if it is in 'down' state. If
# interface is in 'up' state, the following Kernel error will be thrown:
# bond0: eth1 is up - this may be due to an out of date ifenslave.
- Interface(interface).set_state('down')
+ Interface(interface).set_admin_state('down')
return self.set_interface('bond_add_port', f'+{interface}')
def del_port(self, interface):