<div dir="ltr"><div>The second address looks like it comes from link-local, not from DHCP. I suspect you have a higher-priority .network file that also enables DHCP like yours does, but *also* sets "LinkLocalAddressing=both", like some of systemd's built-in example .network files tend to do. Check `networkctl status enp1s0` to verify which .network file is in use.</div><div><br></div><div>(Default is "LinkLocalAddressing=ipv6", don't set it to "no" as that would break IPv6.)</div></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Mon, Jun 2, 2025 at 4:07 PM daggs <<a href="mailto:daggs@gmx.com">daggs@gmx.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Greetings,<br>
<br>
I have a qemu vm which runs a systemd based buildroot image, the vm's nic is virtio, if I configure systemd to auto start the nic, I get two ips for the only nic on the system, a valid one and in invalid one.<br>
in this case, I can only connect to local lan but not outside of the last, I once were able to get to a situation where only the valid ip is set and tested outside connection at it worked.<br>
here is the output of ip a:<br>
<br>
$ ip a<br>
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue qlen 1000<br>
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00<br>
inet <a href="http://127.0.0.1/8" rel="noreferrer" target="_blank">127.0.0.1/8</a> scope host lo<br>
valid_lft forever preferred_lft forever<br>
inet6 ::1/128 scope host noprefixroute <br>
valid_lft forever preferred_lft forever<br>
2: enp1s0: <BROADCAST,MULTICAST,UP,LOWER_UP8000> mtu 1500 qdisc fq_codel qlen 1000<br>
link/ether xx:xx:xx:xx:xx:xx brd ff:ff:ff:ff:ff:ff<br>
inet <a href="http://192.168.0.10/24" rel="noreferrer" target="_blank">192.168.0.10/24</a> brd 192.168.0.255 scope global dynamic enp1s0<br>
valid_lft 40422sec preferred_lft 40422sec<br>
inet <a href="http://169.254.39.180/16" rel="noreferrer" target="_blank">169.254.39.180/16</a> brd 169.254.255.255 scope global enp1s0<br>
valid_lft forever preferred_lft forever<br>
inet6 xxxx::xxxx:xx:xxxx:xxxx/64 scope link <br>
valid_lft forever preferred_lft forever<br>
3: sit0@NONE: <NOARP> mtu 1480 qdisc noop qlen 1000<br>
link/sit 0.0.0.0 brd 0.0.0.0<br>
<br>
$ cat /etc/systemd/network/enp1s0.network<br>
[Match]<br>
Name=enp1s0<br>
[Network]<br>
DHCP=ipv4<br>
<br>
I'm no sure this is a systemd bug as I saw it when I tried a non systemd based env, so I'd like to try and prevent such allocation so the system will work until I can properly solve it.<br>
is it possible?<br>
<br>
Thanks<br>
<br>
Dagg<br>
</blockquote></div>