← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1471957] [NEW] Invalid subnet cidr cause dhcp runtimerror

 

Public bug reported:

Trace:
ERROR neutron.agent.linux.utils [req-26ce0148-4bc4-40bd-96ac-e9d484f37b61 demo 12b3399d1cb64da488e20f6a7c355d10] 
Command: ['sudo', '/usr/local/bin/neutron-rootwrap', '/etc/neutron/rootwrap.conf', 'ip', 'netns', 'exec', 'qdhcp-6cdefebf-ab88-4f55-b2b9-719286a7b75b', 'ip', 'route', 'replace', 'default', 'via', '0.0.0.1', 'dev', 'tapb81e677c-8c']
Exit code: 2
Stdout: ''
Stderr: 'RTNETLINK answers: Network is unreachable\n'
ERROR neutron.agent.dhcp_agent [req-26ce0148-4bc4-40bd-96ac-e9d484f37b61 demo 12b3399d1cb64da488e20f6a7c355d10] Unable to enable dhcp for 6cdefebf-ab88-4f55-b2b9-719286a7b75b.
Traceback (most recent call last):
  File "/opt/stack/neutron/neutron/agent/dhcp_agent.py", line 128, in call_driver
    getattr(driver, action)(**action_kwargs)
  File "/opt/stack/neutron/neutron/agent/linux/dhcp.py", line 205, in enable
    interface_name = self.device_manager.setup(self.network)
  File "/opt/stack/neutron/neutron/agent/linux/dhcp.py", line 1056, in setup
    self._set_default_route(network, interface_name)
  File "/opt/stack/neutron/neutron/agent/linux/dhcp.py", line 928, in _set_default_route
    device.route.add_gateway(subnet.gateway_ip)
  File "/opt/stack/neutron/neutron/agent/linux/ip_lib.py", line 395, in add_gateway
    self._as_root(*args)
  File "/opt/stack/neutron/neutron/agent/linux/ip_lib.py", line 242, in _as_root
    kwargs.get('use_root_namespace', False))
  File "/opt/stack/neutron/neutron/agent/linux/ip_lib.py", line 74, in _as_root
    log_fail_as_error=self.log_fail_as_error)
  File "/opt/stack/neutron/neutron/agent/linux/ip_lib.py", line 86, in _execute
    log_fail_as_error=log_fail_as_error)
  File "/opt/stack/neutron/neutron/agent/linux/utils.py", line 84, in execute
    raise RuntimeError(m)
TRACE neutron.agent.dhcp_agent RuntimeError: 
TRACE neutron.agent.dhcp_agent Command: ['sudo', '/usr/local/bin/neutron-rootwrap', '/etc/neutron/rootwrap.conf', 'ip', 'netns', 'exec', 'qdhcp-6cdefebf-ab88-4f55-b2b9-719286a7b75b', 'ip', 'route', 'replace', 'default', 'vi
a', '0.0.0.1', 'dev', 'tapb81e677c-8c']
TRACE neutron.agent.dhcp_agent Exit code: 2
TRACE neutron.agent.dhcp_agent Stdout: ''
TRACE neutron.agent.dhcp_agent Stderr: 'RTNETLINK answers: Network is unreachable\n'
TRACE neutron.agent.dhcp_agent 


Steps to reproduce:
NET_NAME=test-ip
neutron net-create ${NET_NAME}
neutron port-create ${NET_NAME}
neutron subnet-create ${NET_NAME} 0.0.0.0/8


Impact:
cause logs to grow more than necessary

** Affects: neutron
     Importance: Undecided
         Status: New

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

Title:
  Invalid subnet cidr cause dhcp runtimerror

Status in OpenStack Neutron (virtual network service):
  New

Bug description:
  Trace:
  ERROR neutron.agent.linux.utils [req-26ce0148-4bc4-40bd-96ac-e9d484f37b61 demo 12b3399d1cb64da488e20f6a7c355d10] 
  Command: ['sudo', '/usr/local/bin/neutron-rootwrap', '/etc/neutron/rootwrap.conf', 'ip', 'netns', 'exec', 'qdhcp-6cdefebf-ab88-4f55-b2b9-719286a7b75b', 'ip', 'route', 'replace', 'default', 'via', '0.0.0.1', 'dev', 'tapb81e677c-8c']
  Exit code: 2
  Stdout: ''
  Stderr: 'RTNETLINK answers: Network is unreachable\n'
  ERROR neutron.agent.dhcp_agent [req-26ce0148-4bc4-40bd-96ac-e9d484f37b61 demo 12b3399d1cb64da488e20f6a7c355d10] Unable to enable dhcp for 6cdefebf-ab88-4f55-b2b9-719286a7b75b.
  Traceback (most recent call last):
    File "/opt/stack/neutron/neutron/agent/dhcp_agent.py", line 128, in call_driver
      getattr(driver, action)(**action_kwargs)
    File "/opt/stack/neutron/neutron/agent/linux/dhcp.py", line 205, in enable
      interface_name = self.device_manager.setup(self.network)
    File "/opt/stack/neutron/neutron/agent/linux/dhcp.py", line 1056, in setup
      self._set_default_route(network, interface_name)
    File "/opt/stack/neutron/neutron/agent/linux/dhcp.py", line 928, in _set_default_route
      device.route.add_gateway(subnet.gateway_ip)
    File "/opt/stack/neutron/neutron/agent/linux/ip_lib.py", line 395, in add_gateway
      self._as_root(*args)
    File "/opt/stack/neutron/neutron/agent/linux/ip_lib.py", line 242, in _as_root
      kwargs.get('use_root_namespace', False))
    File "/opt/stack/neutron/neutron/agent/linux/ip_lib.py", line 74, in _as_root
      log_fail_as_error=self.log_fail_as_error)
    File "/opt/stack/neutron/neutron/agent/linux/ip_lib.py", line 86, in _execute
      log_fail_as_error=log_fail_as_error)
    File "/opt/stack/neutron/neutron/agent/linux/utils.py", line 84, in execute
      raise RuntimeError(m)
  TRACE neutron.agent.dhcp_agent RuntimeError: 
  TRACE neutron.agent.dhcp_agent Command: ['sudo', '/usr/local/bin/neutron-rootwrap', '/etc/neutron/rootwrap.conf', 'ip', 'netns', 'exec', 'qdhcp-6cdefebf-ab88-4f55-b2b9-719286a7b75b', 'ip', 'route', 'replace', 'default', 'vi
  a', '0.0.0.1', 'dev', 'tapb81e677c-8c']
  TRACE neutron.agent.dhcp_agent Exit code: 2
  TRACE neutron.agent.dhcp_agent Stdout: ''
  TRACE neutron.agent.dhcp_agent Stderr: 'RTNETLINK answers: Network is unreachable\n'
  TRACE neutron.agent.dhcp_agent 

  
  Steps to reproduce:
  NET_NAME=test-ip
  neutron net-create ${NET_NAME}
  neutron port-create ${NET_NAME}
  neutron subnet-create ${NET_NAME} 0.0.0.0/8

  
  Impact:
  cause logs to grow more than necessary

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


Follow ups

References