Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UseRoutes=false still leads to dropped routes on dhcp renew #12426

Closed
sulaweyo opened this issue Apr 28, 2019 · 3 comments · Fixed by #12427
Closed

UseRoutes=false still leads to dropped routes on dhcp renew #12426

sulaweyo opened this issue Apr 28, 2019 · 3 comments · Fixed by #12427
Labels
bug 🐛 Programming errors, that need preferential fixing dhcp network

Comments

@sulaweyo
Copy link

sulaweyo commented Apr 28, 2019

systemd version the issue has been seen with

systemd 242 (242.0-3-arch)

Used distribution

Arch

Expected behaviour you didn't see

If UseRoutes=false static routes should be stable on dhcp ip refresh

Unexpected behaviour you saw

The static route is working but as soon as the dhcp lease expires and a new lease is acquired the static route is dropped

Steps to reproduce the problem

Set a static route on a dhcp managed interface, set useroutes=false, wait for dhcp renew

My config on the interface
The host has 1 nic, a vlan vnic (with the default gateway on it) and a bridge for kvm as well as other local network stuff. The first route is to have a route to the private network, the second is to get announcements of a upnp streaming server to the correct interface.
This config used to work until arch updated from systemd 241.67-1 to 242.0-3.

[Match]
Name=br0

[Network]
DHCP=ipv4
Domains=my.domain
LinkLocalAddressing=no
IPv6AcceptRA=no
BindCarrier=eno1

[DHCP]
UseRoutes=false
SendHostname=true
Hostname=my-hostname
ClientIdentifier=mac

[Route]
Destination=192.168.1.0/24
Scope=link

[Route]
Destination=239.255.255.250
Scope=link

@yuwata yuwata added dhcp network bug 🐛 Programming errors, that need preferential fixing labels Apr 28, 2019
ssahani pushed a commit to ssahani/systemd that referenced this issue Apr 29, 2019
1. When the DHCPv4 lease expires kernel removes the route. So add it back
when we gain lease again.

Closes systemd#12426

2. When UseRoutes=false do not remove router
@ssahani
Copy link
Contributor

ssahani commented Apr 29, 2019

fix is #12427

ssahani pushed a commit to ssahani/systemd that referenced this issue Apr 29, 2019
1. When the DHCPv4 lease expires kernel removes the route. So add it back
when we gain lease again.

Closes systemd#12426

2. When UseRoutes=false do not remove router
@sulaweyo
Copy link
Author

I have to say i'm highly impressed by your speed! This is just awesome

poettering pushed a commit that referenced this issue Apr 29, 2019
1. When the DHCPv4 lease expires kernel removes the route. So add it back
when we gain lease again.

Closes #12426

2. When UseRoutes=false do not remove router
@ssahani
Copy link
Contributor

ssahani commented Apr 29, 2019

Thank you.

edevolder pushed a commit to edevolder/systemd that referenced this issue Jun 26, 2019
1. When the DHCPv4 lease expires kernel removes the route. So add it back
when we gain lease again.

Closes systemd#12426

2. When UseRoutes=false do not remove router
KJTsanaktsidis pushed a commit to KJTsanaktsidis/systemd that referenced this issue Apr 19, 2020
1. When the DHCPv4 lease expires kernel removes the route. So add it back
when we gain lease again.

Closes systemd#12426

2. When UseRoutes=false do not remove router
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Programming errors, that need preferential fixing dhcp network
Development

Successfully merging a pull request may close this issue.

3 participants