stable to next upgrade-charm hook fails when ovs has references to non-existing interfaces

Bug #1774931 reported by Frode Nordahl on 2018-06-04
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack neutron-gateway charm
Low
Unassigned

Bug Description

2018-06-04 06:38:53 DEBUG upgrade-charm active
2018-06-04 06:38:53 INFO juju-log Creating bridge br-int
2018-06-04 06:38:53 INFO juju-log Creating bridge br-ex
2018-06-04 06:38:53 INFO juju-log Creating bridge br-ex
2018-06-04 06:38:53 DEBUG juju-log Interface ens7 is not a Linux bridge
2018-06-04 06:38:54 INFO juju-log Adding port ens7 to bridge br-ex
2018-06-04 06:38:54 DEBUG upgrade-charm Cannot find device "ens7"
2018-06-04 06:38:54 DEBUG upgrade-charm Traceback (most recent call last):
2018-06-04 06:38:54 DEBUG upgrade-charm File "/var/lib/juju/agents/unit-neutron-gateway-0/charm/hooks/upgrade-charm", line 324, in <module>
2018-06-04 06:38:54 DEBUG upgrade-charm hooks.execute(sys.argv)
2018-06-04 06:38:54 DEBUG upgrade-charm File "/var/lib/juju/agents/unit-neutron-gateway-0/charm/hooks/charmhelpers/core/hookenv.py", line 823, in execute
2018-06-04 06:38:54 DEBUG upgrade-charm self._hooks[hook_name]()
2018-06-04 06:38:54 DEBUG upgrade-charm File "/var/lib/juju/agents/unit-neutron-gateway-0/charm/hooks/charmhelpers/contrib/hardening/harden.py", line 79, in _harden_inner2
2018-06-04 06:38:54 DEBUG upgrade-charm return f(*args, **kwargs)
2018-06-04 06:38:54 DEBUG upgrade-charm File "/var/lib/juju/agents/unit-neutron-gateway-0/charm/hooks/upgrade-charm", line 150, in upgrade_charm
2018-06-04 06:38:54 DEBUG upgrade-charm config_changed()
2018-06-04 06:38:54 DEBUG upgrade-charm File "/var/lib/juju/agents/unit-neutron-gateway-0/charm/hooks/charmhelpers/contrib/openstack/utils.py", line 1449, in wrapped_f
2018-06-04 06:38:54 DEBUG upgrade-charm restart_functions)
2018-06-04 06:38:54 DEBUG upgrade-charm File "/var/lib/juju/agents/unit-neutron-gateway-0/charm/hooks/charmhelpers/core/host.py", line 730, in restart_on_change_helper
2018-06-04 06:38:54 DEBUG upgrade-charm r = lambda_f()
2018-06-04 06:38:54 DEBUG upgrade-charm File "/var/lib/juju/agents/unit-neutron-gateway-0/charm/hooks/charmhelpers/contrib/openstack/utils.py", line 1448, in <lambda>
2018-06-04 06:38:54 DEBUG upgrade-charm (lambda: f(*args, **kwargs)), restart_map, stopstart,
2018-06-04 06:38:54 DEBUG upgrade-charm File "/var/lib/juju/agents/unit-neutron-gateway-0/charm/hooks/charmhelpers/contrib/hardening/harden.py", line 79, in _harden_inner2
2018-06-04 06:38:54 DEBUG upgrade-charm return f(*args, **kwargs)
2018-06-04 06:38:54 DEBUG upgrade-charm File "/var/lib/juju/agents/unit-neutron-gateway-0/charm/hooks/upgrade-charm", line 128, in config_changed
2018-06-04 06:38:54 DEBUG upgrade-charm configure_ovs()
2018-06-04 06:38:54 DEBUG upgrade-charm File "/var/lib/juju/agents/unit-neutron-gateway-0/charm/hooks/neutron_utils.py", line 731, in configure_ovs
2018-06-04 06:38:54 DEBUG upgrade-charm add_bridge_port(br, port, promisc=True)
2018-06-04 06:38:54 DEBUG upgrade-charm File "/var/lib/juju/agents/unit-neutron-gateway-0/charm/hooks/charmhelpers/contrib/network/ovs/__init__.py", line 64, in add_bridge_port
2018-06-04 06:38:54 DEBUG upgrade-charm subprocess.check_call(["ip", "link", "set", port, "up"])
2018-06-04 06:38:54 DEBUG upgrade-charm File "/usr/lib/python3.5/subprocess.py", line 581, in check_call
2018-06-04 06:38:54 DEBUG upgrade-charm raise CalledProcessError(retcode, cmd)
2018-06-04 06:38:54 DEBUG upgrade-charm subprocess.CalledProcessError: Command '['ip', 'link', 'set', 'ens7', 'up']' returned non-zero exit status 1
2018-06-04 06:38:54 ERROR juju.worker.uniter.operation runhook.go:114 hook "upgrade-charm" failed: exit status 1
root@juju-ed0ed4-default-12:/var/log/juju# ovs-vsctl show
797fd91e-70e9-46bd-8a8d-4bceb82884c9
    Manager "ptcp:6640:127.0.0.1"
        is_connected: true
    Bridge br-ex
        Controller "tcp:127.0.0.1:6633"
            is_connected: true
        fail_mode: secure
        Port br-ex
            Interface br-ex
                type: internal
        Port "ens8"
            Interface "ens8"
        Port phy-br-ex
            Interface phy-br-ex
                type: patch
                options: {peer=int-br-ex}
        Port "ens7"
            Interface "ens7"
                error: "could not open network device ens7 (No such device)"
    Bridge br-int
        Controller "tcp:127.0.0.1:6633"
            is_connected: true
        fail_mode: secure
        Port int-br-ex
            Interface int-br-ex
                type: patch
                options: {peer=phy-br-ex}
        Port patch-tun
            Interface patch-tun
                type: patch
                options: {peer=patch-int}
        Port br-int
            Interface br-int
                type: internal
    Bridge br-tun
        Controller "tcp:127.0.0.1:6633"
            is_connected: true
        fail_mode: secure
        Port br-tun
            Interface br-tun
                type: internal
        Port patch-int
            Interface patch-int
                type: patch
                options: {peer=patch-tun}
    ovs_version: "2.9.0"

Frode Nordahl (fnordahl) wrote :

The extraneous ports get there whenever you deploy neutron gateway with incorrect setting for data-port and subsequently correct it. Or I guess any deployment that has the data-port updated from one interface to another during its lifetime will look like this.

James Page (james-page) on 2018-07-17
Changed in charm-neutron-gateway:
status: New → Triaged
importance: Undecided → Low
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers