← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1489091] Re: neutron l3-agent-router-remove is not unscheduling dvr routers from L3-agents

 

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

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

Title:
  neutron l3-agent-router-remove is not unscheduling dvr routers from
  L3-agents

Status in neutron:
  Fix Released

Bug description:
  In my environment where there is a compute node and a controller node.
  On the compute node the L3-agent mode is 'dvr'.
  On the controller node the L3-agent mode is 'dvr-snat'.
  Nova-compute is only running on the compute node.

  Start: the compute node has no VMs running, there are no namespaces on
  the compute node.

  1. Created a network and a router
     neutron net-create my-net
     neutron subnet-create sb-my-net my-net 10.1.2.0/24
     neutron router-create my-router
     neutron router-interface-add my-router sb-my-net
     neutron router-gateway-set my-router public

  my-net's UUID is 1162f283-6efc-424a-af37-0fbeeaf5d02a
  my-router's UUID is 4f357733-9320-4c67-a0f6-81054d40fdaa

  2. Boot a VM
     nova boot --flavor 1 --image <IMAGE> --nic net-id=1162f283-6efc-424a-af37-0fbeeaf5d02a myvm
     - The VM is hosted on the compute node.

  3. Assign a floating IP to the VM
      neutron port-list --device-id <vm-uuid>
      neutron floatingip-create --port-id <vm-port-uuid> public

  The fip namespace and the qrouter-
  4f357733-9320-4c67-a0f6-81054d40fdaa is found on the compute node.

  4. Delete the VM. On the compute node, the fip namespace went away as expected.  But the qrouter namespace is left behind, but it should have been deleted. Neutron l3-agent-list-hosting-router shows the router is still scheduled on the compute node's L3-agent.
  stack@Dvr-Ctrl2:~/DEVSTACK/manage$ nova list
  +----+------+--------+------------+-------------+----------+
  | ID | Name | Status | Task State | Power State | Networks |
  +----+------+--------+------------+-------------+----------+
  +----+------+--------+------------+-------------+----------+
  stack@Dvr-Ctrl2:~/DEVSTACK/manage$ ./osadmin neutron l3-agent-list-hosting-router 4f357733-9320-4c67-a0f6-81054d40fdaa
  +--------------------------------------+-------------+----------------+-------+----------+
  | id                                   | host        | admin_state_up | alive | ha_state |
  +--------------------------------------+-------------+----------------+-------+----------+
  | 4fb0bc93-2e6b-46c7-9ccd-3c66d1f44cfc | Dvr-Ctrl2   | True           | :-)   |          |
  | 733e31eb-b49e-488b-aaf1-0dbcda802f66 | DVR-Compute | True           | :-)   |          |
  +--------------------------------------+-------------+----------------+-------+----------+

  5. Attempt to use neutron l3-agent-router-remove to remove the router from the compute node's L3-agent also didn't work.  The router is still scheduled on the agent.
  stack@Dvr-Ctrl2:~/DEVSTACK/manage$ ./osadmin neutron l3-agent-router-remove 733e31eb-b49e-488b-aaf1-0dbcda802f66 4f357733-9320-4c67-a0f6-81054d40fdaa
  Removed router 4f357733-9320-4c67-a0f6-81054d40fdaa from L3 agent

  stack@Dvr-Ctrl2:~/DEVSTACK/manage$ ./osadmin neutron l3-agent-list-hosting-router 4f357733-9320-4c67-a0f6-81054d40fdaa
  +--------------------------------------+-------------+----------------+-------+----------+
  | id                                   | host        | admin_state_up | alive | ha_state |
  +--------------------------------------+-------------+----------------+-------+----------+
  | 4fb0bc93-2e6b-46c7-9ccd-3c66d1f44cfc | Dvr-Ctrl2   | True           | :-)   |          |
  | 733e31eb-b49e-488b-aaf1-0dbcda802f66 | DVR-Compute | True           | :-)   |          |
  +--------------------------------------+-------------+----------------+-------+----------+

  The errors in (4) and (5) did not happen on the stable/kilo or the stable/juno code:
     i.) In (4) the router should no longer be scheduled on the compute node's L3 agent.
     ii.) In (5) neutron l3-agent-router-remove should removed the router from the compute node's L3 agent.

  Both (4) and (5) indicates that no notification to remove the router
  is sent to the L3-agent on the compute node.  They represent
  regressions in the latest neutron code.

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


References