← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1464527] Re: Don't delete DVR Namespace when there are still ports not in ACTIVE state.

 

** Changed in: neutron
       Status: Fix Committed => Fix Released

** Changed in: neutron
    Milestone: None => liberty-1

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

Title:
  Don't delete DVR Namespace when there are still ports not in ACTIVE
  state.

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

Bug description:
  In one openstack with multiple neutron-servers behind a haproxy, in bellow use case, VM can't communicate with others in DVR,
  reproduce steps:
  1. create a subnet and add this subnet to a DVR
  2. bulk create two VMs with a specail compute node(this node does not include any VMs in this subnet) in this subnet
  3. when a VM port status is ACTIVE, but another VM port status is BUILD, delete the VM which port status is ACTIVE
  then I can't find the namespace of this DVR router, the reason is that when it 'delete_port', it will check the the all the ports status in this host and subnet using 'check_ports_active_on_host_and_subnet', but it check port ACTIVE status, sometimes a VM's port status will be BUILD

   def check_ports_active_on_host_and_subnet(self, context, host,port_id, subnet_id):
       """Check if there is any dvr serviceable port on the subnet_id."""
       filter_sub = {'fixed_ips': {'subnet_id': [subnet_id]}}
       ports = self._core_plugin.get_ports(context, filters=filter_sub)
       for port in ports:
           if (n_utils.is_dvr_serviced(port['device_owner'])
               and port['status'] == 'ACTIVE'
               and port['binding:host_id'] == host
               and port['id'] != port_id):
               LOG.debug('DVR: Active port exists for subnet %(subnet_id)s '
                         'on host %(host)s', {'subnet_id': subnet_id,
                                      'host': host})
               return True
       return False

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


References