mirror of
https://github.com/CumulusNetworks/ifupdown2.git
synced 2024-05-06 15:54:50 +00:00
addons: vlan: fix checking of vlan device in query-running
Ticket: CM-11804 Reviewed By: julien, nikhil Testing Done: Tested with failing config in the bug This patch makes sure macvlan devices are ignored by ifquery -ra Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com>
This commit is contained in:
@@ -188,12 +188,12 @@ class vlan(moduleBase):
|
||||
def _query_running(self, ifaceobjrunning):
|
||||
if not self.ipcmd.link_exists(ifaceobjrunning.name):
|
||||
return
|
||||
if not self.ipcmd.get_vlandev_attrs(ifaceobjrunning.name):
|
||||
(vlanrawdev, vlanid) = self.ipcmd.get_vlandev_attrs(ifaceobjrunning.name)
|
||||
if not vlanid:
|
||||
return
|
||||
# If vlan name is not in the dot format, get the
|
||||
# vlan dev and vlan id
|
||||
if not '.' in ifaceobjrunning.name:
|
||||
(vlanrawdev, vlanid) = self.ipcmd.get_vlandev_attrs(ifaceobjrunning.name)
|
||||
ifaceobjrunning.update_config_dict({(k, v) for k, v in
|
||||
{'vlan-raw-device' : vlanrawdev,
|
||||
'vlan-id' : vlanid}.items()
|
||||
|
Reference in New Issue
Block a user