yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #83324
[Bug 1888121] Re: L3 agent fails to update routers with onlink gateway
*** This bug is a duplicate of bug 1861674 ***
https://bugs.launchpad.net/bugs/1861674
** Changed in: neutron
Status: New => Incomplete
** Changed in: neutron
Status: Incomplete => Confirmed
** This bug has been marked a duplicate of bug 1861674
Gateway which is not in subnet CIDR is unsupported in ha router
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1888121
Title:
L3 agent fails to update routers with onlink gateway
Status in neutron:
Confirmed
Bug description:
If a router uses an external gateway network with an "onlink" gateway
(= gateway not in subnet range), L3 agents fails to process router
update.
* Versions: currently in Train, since the code did not changed I think
in Ussuri too.
* How to reproduce:
# Create external network
openstack network create public --external
# Create associated subnet with a gateway not in the subnet range. This kind of gateway should be
# handle as an "onlink" route.
openstack subnet create --network public --subnet-range 192.168.144.0/24 --gateway 192.168.0.1
# Create router and set external gateway
openstack router create external
openstack router set --external-gateway public
# Check l3 agent logs
http://paste.openstack.org/show/796084/
* Current fix:
During gateway setup here
https://github.com/openstack/neutron/blob/stable/train/neutron/agent/linux/ip_lib.py#L604,
adding 'onlink' flag allows pyroute2 to successfully add the onlink
default gateway:
```
def add_gateway(self, gateway, metric=None, table=None, scope='global', flags=[]):
kwargs = {'flags': ['onlink']}
self.add_route(None, via=gateway, table=table, metric=metric,
scope=scope, **kwargs)
```
Result: http://paste.openstack.org/show/796085/
About the patch, I don't really know the consequences of adding the onlink flag standards gateway. Maybe we could add a check "if 'gateway not in subnet cidr' then onlink", this will impact all existing routers otherwise.
To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1888121/+subscriptions
References