In an environment with multiple neutron-servers, I have observed that a router can get scheduled to an l3-agent more than once. A "neutron l3-agent-list-hosting-router <router id>" will show the router scheduled twice to the same l3-agent or perhaps to two different agents. This can be reproduced using devstack. A second neutron-server on another host has to be configured. Executing a script against each of the neutron-servers which adds (neutron l3-agent-router-add) and removes (neutron l3-agent-router-remove) a router from an l3 agent is the quickest way to reproduce the race condition. There is no locking or other coordination across multiple neutron-server processes to prevent this.
Fix proposed to branch: master /review. openstack. org/48357
Review: https:/