Public bug reported: once an external gateway is set, due to a logic error, for every subsequent router update the L-3 agent incorrectly concludes there is a change in external gateway. This causes the codepath to set external gateway getting invoked un-necessarily.
In process_router(...) .... ex_gw_port = self._get_ex_gw_port(ri) returns ri.router.get('gw_port') ... if ex_gw_port and ex_gw_port != ri.ex_gw_port: self._set_subnet_info(ex_gw_port) <-------- ... ri.ex_gw_port = ex_gw_port The _set_subnet_info adds an element to the ex_gw_port thus making it different from the gw_port obtained out of router dict. Any subsequent ex_gw_port != ri.ex_gw_port would result True, incorrectly. One way to fix it would be to change From: if ex_gw_port and ex_gw_port != ri.ex_gw_port: To: if (ex_gw_port and (not ri.ex_gw_port or ex_gw_port['id'] != ri.ex_gw_port['id'])): ** 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/1348737 Title: Once a Gateway is set L-3 agent attempts to update external Gateway on every router update Status in OpenStack Neutron (virtual network service): New Bug description: once an external gateway is set, due to a logic error, for every subsequent router update the L-3 agent incorrectly concludes there is a change in external gateway. This causes the codepath to set external gateway getting invoked un-necessarily. In process_router(...) .... ex_gw_port = self._get_ex_gw_port(ri) returns ri.router.get('gw_port') ... if ex_gw_port and ex_gw_port != ri.ex_gw_port: self._set_subnet_info(ex_gw_port) <-------- ... ri.ex_gw_port = ex_gw_port The _set_subnet_info adds an element to the ex_gw_port thus making it different from the gw_port obtained out of router dict. Any subsequent ex_gw_port != ri.ex_gw_port would result True, incorrectly. One way to fix it would be to change From: if ex_gw_port and ex_gw_port != ri.ex_gw_port: To: if (ex_gw_port and (not ri.ex_gw_port or ex_gw_port['id'] != ri.ex_gw_port['id'])): To manage notifications about this bug go to: https://bugs.launchpad.net/neutron/+bug/1348737/+subscriptions -- Mailing list: https://launchpad.net/~yahoo-eng-team Post to : yahoo-eng-team@lists.launchpad.net Unsubscribe : https://launchpad.net/~yahoo-eng-team More help : https://help.launchpad.net/ListHelp