IPVPN OVS driver: Exception getting MPLS interface (patch port case) MAC address

Bug #1818837 reported by yannick thomas
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
BaGPipe
Fix Released
Undecided
yannick thomas

Bug Description

Using IPVPN OVS driver in bare MPLS use case with a patch port as MPLS interface, result in throwing an exception:

mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: DEBUG networking_bagpipe.bagpipe_bgp.vpn.ipvpn.mpls_ovs_dataplane [-] Running command in subshell mode: cat /sys/class/net/patch-to-ex/address {{(pid=23122) run_command /opt/stack/ne
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: DEBUG networking_bagpipe.bagpipe_bgp.vpn.ipvpn.mpls_ovs_dataplane [-] run_command stderr: cat: /sys/class/net/patch-to-ex/address: No such file or directory {{(pid=23122) _log_stdx_
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.vpn.ipvpn.mpls_ovs_dataplane [-] Exit code 1 when running 'cat /sys/class/net/patch-to-ex/address'
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.vpn.ipvpn.mpls_ovs_dataplane [-] run_command stderr: cat: /sys/class/net/patch-to-ex/address: No such file or directory
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: DEBUG networking_bagpipe.bagpipe_bgp.vpn.ipvpn.mpls_ovs_dataplane [-] Running command in subshell mode: cat /sys/class/net/<networking_bagpipe.bagpipe_bgp.common.dataplane_utils.OVSBr
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: DEBUG networking_bagpipe.bagpipe_bgp.vpn.ipvpn.mpls_ovs_dataplane [-] run_command stderr: /bin/sh: 1: cannot open networking_bagpipe.bagpipe_bgp.common.dataplane_utils.OVSBridgeWith
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.vpn.ipvpn.mpls_ovs_dataplane [-] Exit code 2 when running 'cat /sys/class/net/<networking_bagpipe.bagpipe_bgp.common.dataplane_utils.OVSBridgeWith
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.vpn.ipvpn.mpls_ovs_dataplane [-] run_command stderr: /bin/sh: 1: cannot open networking_bagpipe.bagpipe_bgp.common.dataplane_utils.OVSBridgeWith
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.vpn.ipvpn.mpls_ovs_dataplane [-] Exception while initializing dataplane state: Exit code 2 when running 'cat /sys/class/net/<networking_bagpipe.ba
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers [-] attach_localport: An error occurred during local port plug to VPN: Exception: Exit code 2 when running 'cat /sys/class/net/<ne
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers Traceback (most recent call last):
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/api/controllers.py", line 217, in process
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers self.manager.plug_vif_to_vpn(**attach_params)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/common/log_decorator.py", line 39, in wrapper
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers return method(*args, **kwargs)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/vpn/manager.py", line 360, in plug_vif_to_vpn
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers fallback, **kwargs)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/common/utils.py", line 31, in synchronized_method
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers return method(self, *arg, **kws)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/common/log_decorator.py", line 39, in wrapper
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers return method(*args, **kwargs)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/vpn/manager.py", line 269, in _get_vpn_instance
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers fallback, **kwargs)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/common/log_decorator.py", line 39, in wrapper
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers return method(*args, **kwargs)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/vpn/ipvpn/__init__.py", line 78, in __init__
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers vpn_instance.VPNInstance.__init__(self, *args, **kwargs)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/common/log_decorator.py", line 39, in wrapper
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers return method(*args, **kwargs)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/vpn/vpn_instance.py", line 333, in __init__
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers self.gateway_ip, self.network_plen, self.instance_label, **kwargs)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/common/log_decorator.py", line 39, in wrapper
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers return method(*args, **kwargs)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/vpn/dataplane_drivers.py", line 205, in initialize_dataplane_
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers self.initialize()
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/vpn/ipvpn/mpls_ovs_dataplane.py", line 1126, in initialize
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers self.bridge)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/common/net_utils.py", line 31, in get_device_mac
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers (command_prefix, dev_name))
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/vpn/dataplane_drivers.py", line 250, in _run_command
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers *args, **kwargs)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers File "/opt/stack/networking-bagpipe/networking_bagpipe/bagpipe_bgp/common/run_command.py", line 145, in run_command
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers raise Exception(message)
mars 06 11:08:03 l-navi-tessa bagpipe-bgp[23122]: ERROR networking_bagpipe.bagpipe_bgp.api.controllers Exception: Exit code 2 when running 'cat /sys/class/net/<networking_bagpipe.bagpipe_bgp.common.dataplane_utils.OVSBridgeWithGroups

This exception is due to use self.bridge instead of self.bridge.br_name at https://github.com/openstack/networking-bagpipe/blob/master/networking_bagpipe/bagpipe_bgp/vpn/ipvpn/mpls_ovs_dataplane.py#L1126

Changed in networking-bagpipe:
assignee: nobody → yannick thomas (ythomas1-ext)
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to networking-bagpipe (master)

Fix proposed to branch: master
Review: https://review.openstack.org/643884

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to networking-bagpipe (master)

Reviewed: https://review.openstack.org/643884
Committed: https://git.openstack.org/cgit/openstack/networking-bagpipe/commit/?id=0182d11249cf479c3fa69f87e21918031e9949e9
Submitter: Zuul
Branch: master

commit 0182d11249cf479c3fa69f87e21918031e9949e9
Author: ythomas1 <email address hidden>
Date: Mon Mar 18 09:37:53 2019 +0100

    bagpipe-bgp: fix IPVPN OVS driver in patch port case

    Since code was refactored to use OVSBridge class, we need to use
    self.bridge.br_name instead of self.bridge to retrieve bridge name.

    Signed-off-by: Thomas Morin <email address hidden>
    Submitted on behalf of a third-party: Orange

    Change-Id: I0126149e9f1ec13d6799c68a780e0c488768902d
    Closes-Bug: 1818837

Changed in networking-bagpipe:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/networking-bagpipe 11.0.0.0b1

This issue was fixed in the openstack/networking-bagpipe 11.0.0.0b1 development milestone.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.