From 5f87266d9ef3b72908b6f429e37df280f1be8cdf Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Fri, 6 Sep 2019 10:54:50 +0200 Subject: bonding: T1614: members are not allowed to be underlaying vxlan devices --- src/conf_mode/interface-bonding.py | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/conf_mode') diff --git a/src/conf_mode/interface-bonding.py b/src/conf_mode/interface-bonding.py index acf088de8..bce8f98fb 100755 --- a/src/conf_mode/interface-bonding.py +++ b/src/conf_mode/interface-bonding.py @@ -306,6 +306,13 @@ def verify(bond): raise ConfigError('can not enslave interface {} which belongs to ' \ 'pseudo-ethernet {}'.format(intf, tmp)) + # bond members are not allowed to be underlaying vxlan devices + for tmp in conf.list_nodes('interfaces vxlan'): + if conf.exists('interfaces vxlan ' + tmp + ' link ' + intf): + raise ConfigError('can not enslave interface {} which belongs to ' \ + 'vxlan {}'.format(intf, tmp)) + + if bond['primary']: if bond['primary'] not in bond['member']: raise ConfigError('primary interface must be a member interface of {}' \ -- cgit v1.2.3