← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1291915] Re: neutron-netns-cleanup script doesn't work in icehouse/havana, code is broken

 

** Changed in: neutron
    Milestone: juno-1 => icehouse-rc2

** No longer affects: neutron/icehouse

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1291915

Title:
  neutron-netns-cleanup script doesn't work in icehouse/havana, code is
  broken

Status in OpenStack Neutron (virtual network service):
  Fix Committed

Bug description:
  1st) Some configuration options are not registered on the tool, but
  they're used in neutron.agent.linux.dhcp  during execution

  $ neutron-netns-cleanup --debug --force --config-file /etc/neutron/neutron.conf --config-file /etc/neutron/dhcp_agent.ini --config-file  /etc/neutron/plugins/ml2/ml2_conf.ini
  2014-03-12 14:55:44.791 INFO neutron.common.config [-] Logging enabled!
  2014-03-12 14:55:44.792 DEBUG neutron.agent.linux.utils [-] Running command: ['sudo', '/usr/bin/neutron-rootwrap', '/etc/neutron/rootwrap.conf', 'ip', 'netns', 'list'] from (pid=1785) create_process /opt/stack/neutron/neutron/agent/linux/utils.py:48
  2014-03-12 14:55:45.001 DEBUG neutron.agent.linux.utils [-]
  Command: ['sudo', '/usr/bin/neutron-rootwrap', '/etc/neutron/rootwrap.conf', 'ip', 'netns', 'list']
  Exit code: 0
  Stdout: 'qdhcp-65cb66de-82d0-407c-aa23-2c544528f0d2\nqrouter-acc5f724-a169-4ffc-9e81-f00d43954509\nqrouter-5ed23337-9538-4994-823f-c64720506e54\n'
  Stderr: '' from (pid=1785) execute /opt/stack/neutron/neutron/agent/linux/utils.py:74
  2014-03-12 14:55:47.006 ERROR neutron.agent.linux.dhcp [-] Error importing interface driver 'neutron.agent.linux.interface.OVSInterfaceDriver': no such option: ovs_use_veth
  Error importing interface driver 'neutron.agent.linux.interface.OVSInterfaceDriver': no such option: ovs_use_veth

  2nd) When we try to destroy a network, there's a dependency on the
  .namespace attribute of the network, that wasn't before.

  Stderr: '' from (pid=1969) execute /opt/stack/neutron/neutron/agent/linux/utils.py:74
  2014-03-12 15:08:53.048 ERROR neutron.agent.netns_cleanup_util [-] Error unable to destroy namespace: qdhcp-65cb66de-82d0-407c-aa23-2c544528f0d2
  2014-03-12 15:08:53.048 TRACE neutron.agent.netns_cleanup_util Traceback (most recent call last):
  2014-03-12 15:08:53.048 TRACE neutron.agent.netns_cleanup_util   File "/opt/stack/neutron/neutron/agent/netns_cleanup_util.py", line 131, in destroy_namespace
  2014-03-12 15:08:53.048 TRACE neutron.agent.netns_cleanup_util     kill_dhcp(conf, namespace)
  2014-03-12 15:08:53.048 TRACE neutron.agent.netns_cleanup_util   File "/opt/stack/neutron/neutron/agent/netns_cleanup_util.py", line 86, in kill_dhcp
  2014-03-12 15:08:53.048 TRACE neutron.agent.netns_cleanup_util     dhcp_driver.disable()
  2014-03-12 15:08:53.048 TRACE neutron.agent.netns_cleanup_util   File "/opt/stack/neutron/neutron/agent/linux/dhcp.py", line 181, in disable
  2014-03-12 15:08:53.048 TRACE neutron.agent.netns_cleanup_util     self.device_manager.destroy(self.network, self.interface_name)
  2014-03-12 15:08:53.048 TRACE neutron.agent.netns_cleanup_util   File "/opt/stack/neutron/neutron/agent/linux/dhcp.py", line 814, in destroy
  2014-03-12 15:08:53.048 TRACE neutron.agent.netns_cleanup_util     self.driver.unplug(device_name, namespace=network.namespace)
  2014-03-12 15:08:53.048 TRACE neutron.agent.netns_cleanup_util AttributeError: 'FakeNetwork' object has no attribute 'namespace'
  2014-03-12 15:08:53.048 TRACE neutron.agent.netns_cleanup_util

  3rd) This error will happen because no plugin rpc connection is provided, 
  and that's used in /opt/stack/neutron/neutron/agent/linux/dhcp.py as self.plugin.release_dhcp_port

  2014-03-13 12:00:07.880 ERROR neutron.agent.netns_cleanup_util [-] Error unable to destroy namespace: qdhcp-388a37af-556d-4f4c-98b4-0ba41f944e32
  2014-03-13 12:00:07.880 TRACE neutron.agent.netns_cleanup_util Traceback (most recent call last):
  2014-03-13 12:00:07.880 TRACE neutron.agent.netns_cleanup_util   File "/opt/stack/neutron/neutron/agent/netns_cleanup_util.py", line 132, in destroy_namespace
  2014-03-13 12:00:07.880 TRACE neutron.agent.netns_cleanup_util     kill_dhcp(conf, namespace)
  2014-03-13 12:00:07.880 TRACE neutron.agent.netns_cleanup_util   File "/opt/stack/neutron/neutron/agent/netns_cleanup_util.py", line 87, in kill_dhcp
  2014-03-13 12:00:07.880 TRACE neutron.agent.netns_cleanup_util     dhcp_driver.disable()
  2014-03-13 12:00:07.880 TRACE neutron.agent.netns_cleanup_util   File "/opt/stack/neutron/neutron/agent/linux/dhcp.py", line 181, in disable
  2014-03-13 12:00:07.880 TRACE neutron.agent.netns_cleanup_util     self.device_manager.destroy(self.network, self.interface_name)
  2014-03-13 12:00:07.880 TRACE neutron.agent.netns_cleanup_util   File "/opt/stack/neutron/neutron/agent/linux/dhcp.py", line 816, in destroy
  2014-03-13 12:00:07.880 TRACE neutron.agent.netns_cleanup_util     self.plugin.release_dhcp_port(network.id,
  2014-03-13 12:00:07.880 TRACE neutron.agent.netns_cleanup_util AttributeError: 'NoneType' object has no attribute 'release_dhcp_port'
  2014-03-13 12:00:07.880 TRACE neutron.agent.netns_cleanup_util

To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1291915/+subscriptions


References