I found some clue, but not the root cause yet.
The eth0 is renamed to enp0s2 by 80-net-setup-link.rules udev rule in systemd. 
And the connman.conf only blacklists eth0.

The related log is:
Aug 08 15:18:16 qemux86-64 kernel[213]: [    1.727332] virtio_net virtio0 
enp0s2: renamed from eth0 (while UP)

The systemd udev configuration file is:
root@qemux86-64:~# cat /lib/udev/rules.d/80-net-setup-link.rules
# do not edit this file, it will be overwritten on update
SUBSYSTEM!="net", GOTO="net_setup_link_end"
IMPORT{builtin}="path_id"
ACTION=="remove", GOTO="net_setup_link_end"
IMPORT{builtin}="net_setup_link"
NAME=="", ENV{ID_NET_NAME}!="", NAME="$env{ID_NET_NAME}"
LABEL="net_setup_link_end"

And the connman configuration file is:
root@qemux86-64:~# cat /etc/connman/main.conf
[General]
NetworkInterfaceBlacklist = eth0

In contrary, with 6.1 kernel, the renaming failed with the following message:
Aug 08 15:29:58 qemux86-64 (udev-worker)[206]: enp0s2: Network interface 'eth0' 
is already up, cannot rename to 'enp0s2'.

Maybe some changes in new kernel allows renaming network interface while it's 
up?

Regards,
Qi


-----Original Message-----
From: openembedded-core@lists.openembedded.org 
<openembedded-core@lists.openembedded.org> On Behalf Of Richard Purdie
Sent: Tuesday, August 8, 2023 7:51 PM
To: openembedded-core <openembedded-core@lists.openembedded.org>
Cc: Luca Boccassi <bl...@debian.org>; Alexandre Belloni 
<alexandre.bell...@bootlin.com>
Subject: [OE-core] systemd issue with network commandline config and 6.4 kernel

Hi,

We'd like to switch to the 6.4 kernel and there are two blockers. One of them 
is that systemd appears to be breaking the network device config with 6.4 
kernels.

This happens with core-image-sato but not with core-image-minimal.

In the sato image, I can see the kernel gets the ip= commandline parameters and 
sets up the network (IP-Config: Complete: <correct
info>) in the dmesg logs. When I look at the "ip addr" config, that
setup is gone though.

The autobuilder manifestation of this is for example:

https://autobuilder.yoctoproject.org/typhoon/#/builders/72/builds/7580/steps/23/logs/stdio

i.e. ping fails.

Does anyone know why updating from the 6.1 kernel to the the 6.4 kernel would 
cause this only for systemd images?

I couldn't spot anything in the journal but I'm not sure I'd know what to look 
for...

Thanks,

Richard
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#185664): 
https://lists.openembedded.org/g/openembedded-core/message/185664
Mute This Topic: https://lists.openembedded.org/mt/100620069/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to