]> git.ipfire.org Git - thirdparty/systemd.git/commit
network: reset 'configured' flags even if we keep DHCP lease and friends on reconfigure
authorYu Watanabe <watanabe.yu+github@gmail.com>
Thu, 7 Nov 2024 00:52:03 +0000 (09:52 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Mon, 11 Nov 2024 02:53:24 +0000 (11:53 +0900)
commit52f46b77d7bafb7ce44f016e1793862873a3fc73
tree3c6e48e9d42868fb014f7a67cc74db1009c9174d
parent525a582ae860cd3afed3b7d64ed7b80b2a841909
network: reset 'configured' flags even if we keep DHCP lease and friends on reconfigure

Follow-up for 451c2baf30f50b95d73e648058c7c2348dbf0c31.

With the commits, reloading .network files does not release previously
acquired DHCP lease and friends if possible. If previously a DHCP client
was configured as not requesting DNS servers or so, then the previously
acquired lease might not contain any DNS servers. In that case, if the
new .network file enables UseDNS=, then the interface should enter the
configured state after a new lease is acquired. To achieve that, we need
to reset the flags.

With this change, the workaround applied to the test by the commit
451c2baf30f50b95d73e648058c7c2348dbf0c31 can be dropped.
src/network/networkd-link.c
test/test-network/systemd-networkd-tests.py