I’m following Stefan’s instructions from this answer:
I have this wired.network in /usr/lib/systemd/network :
[Match] Name=eth0 [Network] Address=192.168.102.1/24
Immediately after boot this works fine:
# ifconfig eth0 Link encap:Ethernet HWaddr 00:14:2D:4A:4B:CF inet addr:192.168.102.1 Bcast:192.168.102.255 Mask:255.255.255.0
However, if I modify the IP address e.g. 192.168.102.2 and issue a systemctl restart systemd-networkd the ifconfig output does not change (as it should, as far as I can understand). However, this is the output from networkctl status:
# networkctl status ● State: routable Address: 192.168.102.1 on eth0 192.168.102.2 on eth0 192.168.11.1 on usb0 fe80::214:2dff:fe4a:4bcf on eth0
And if I change the IP address to end with 3 and restart the service another record is added to this list. The device will now answer pings on all 3 IP addresses. ifconfig output is still unchanged from the listing above, i.e. it report the IP address the device booted with, not the “latest” one.
This seems like a bug to me but could of course be some feature that I don’t understand. Could you please look into this?