with dnsmasq server setup:

$ ip -4 a show ens8
3: ens8: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP 
group default qlen 1000
    inet 1.2.3.1/24 scope global ens8
       valid_lft forever preferred_lft forever
$ cat /etc/dnsmasq.d/test 

interface=ens8
bind-dynamic

no-resolv
no-poll

domain=test,1.2.3.4/24
dhcp-range=test,1.2.3.100,1.2.3.199,1m
dhcp-host=52:54:00:f7:b2:99,1.2.3.50,1m


on the test system:

ubuntu@lp1831787-e:~$ dpkg -l systemd | grep ii
ii  systemd        242-7ubuntu3.2 amd64        system and service manager
ubuntu@lp1831787-e:~$ ip -4 a show dev ens8
3: ens8: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP 
group default qlen 1000
    inet 1.2.3.50/24 brd 1.2.3.255 scope global dynamic ens8
       valid_lft 106sec preferred_lft 106sec
ubuntu@lp1831787-e:~$ ip -4 r
default via 1.2.3.1 dev ens8 proto dhcp src 1.2.3.50 metric 1024 
1.2.3.0/24 dev ens8 proto kernel scope link src 1.2.3.50 
1.2.3.1 dev ens8 proto dhcp scope link src 1.2.3.50 metric 1024 


then on dnsmasq server, change the test system addr to .60:

$ cat /etc/dnsmasq.d/test

interface=ens8
bind-dynamic

no-resolv
no-poll

domain=test,1.2.3.4/24
dhcp-range=test,1.2.3.100,1.2.3.199,1m
dhcp-host=52:54:00:f7:b2:99,1.2.3.60,1m


ubuntu@dhcp-test:~$ sudo systemctl restart dnsmasq


on test system, wait for dhcp lease to timeout:

ubuntu@lp1831787-e:~$ ip -4 a show dev ens8
3: ens8: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP 
group default qlen 1000
    inet 1.2.3.60/24 brd 1.2.3.255 scope global dynamic ens8
       valid_lft 114sec preferred_lft 114sec
ubuntu@lp1831787-e:~$ ip -4 r
default via 1.2.3.1 dev ens8 proto dhcp src 1.2.3.60 metric 1024 
1.2.3.0/24 dev ens8 proto kernel scope link src 1.2.3.60 
1.2.3.1 dev ens8 proto dhcp scope link src 1.2.3.60 metric 1024 



** Tags removed: verification-needed verification-needed-eoan
** Tags added: verification-done verification-done-eoan

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1831787

Title:
  Bogus routes after DHCP lease change

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

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to