[systemd-devel] systemd-networkd only brings up network interfaces when systemd-udevd sleeps for 5 seconds

deffo at gmx.de deffo at gmx.de
Thu May 7 08:00:50 UTC 2020


Hi there!

I'm on a Yocto system with latest v241 stable systemd. The odd thing is, that systemd-networkd only brings up network interfaces when systemd-udevd sleeps for 5 seconds at boot up.

If I write the two lines

[Service]
ExecStartPost=/bin/sleep 5

to /etc/systemd/system/systemd-udevd.service.d/override.conf both network interfaces enp2s0 and enp3s0 come up like a charm. If I omit the two lines in override.conf the two interfaces stay down. I attached the two logs with systemd.log_level=debug udev.log_priority=debug enabled.

It's remarkable that the order of the init phase of the interfaces switches in the not working case

Line 6311: May 06 10:31:23 systemd-networkd[185]: enp2s0: New device has no master, continuing without
Line 6312: May 06 10:31:23 systemd-networkd[185]: enp2s0: Flags change: +MULTICAST +BROADCAST
Line 6313: May 06 10:31:23 systemd-networkd[185]: enp2s0: Link 2 added
Line 6314: May 06 10:31:23 systemd-networkd[185]: enp2s0: udev initialized link
Line 6315: May 06 10:31:23 systemd-networkd[185]: enp2s0: Saved original MTU: 1500
Line 6337: May 06 10:31:23 systemd-networkd[185]: enp2s0: Link state is up-to-date
Line 6338: May 06 10:31:23 systemd-networkd[185]: enp2s0: Unmanaged
Line 10255: May 06 10:31:24 systemd-udevd[151]: enp2s0: Device (SEQNUM=2362, ACTION=move) is queued
Line 10256: May 06 10:31:24 systemd-udevd[151]: enp2s0: sd-device-monitor: Passed 262 byte to netlink monitor
Line 10323: May 06 10:31:24 systemd-udevd[162]: enp2s0: Processing device (SEQNUM=2362, ACTION=move)
Line 10327: May 06 10:31:24 systemd-udevd[162]: enp2s0: IMPORT builtin 'net_id' /lib/udev/rules.d/75-net-description.rules:6
Line 10329: May 06 10:31:24 systemd-udevd[162]: enp2s0: IMPORT builtin 'hwdb' /lib/udev/rules.d/75-net-description.rules:12
Line 10330: May 06 10:31:24 systemd-udevd[162]: enp2s0: IMPORT builtin 'path_id' /lib/udev/rules.d/80-net-setup-link.rules:5
Line 10331: May 06 10:31:24 systemd-udevd[162]: enp2s0: sd-device: Created db file '/run/udev/data/n2' for '/devices/pci0000:00/0000:00:13.1/0000:02:00.0/net/enp2s0'
Line 10331: May 06 10:31:24 systemd-udevd[162]: enp2s0: sd-device: Created db file '/run/udev/data/n2' for '/devices/pci0000:00/0000:00:13.1/0000:02:00.0/net/enp2s0'
Line 10332: May 06 10:31:24 systemd-udevd[162]: enp2s0: Device (SEQNUM=2362, ACTION=move) processed
Line 10333: May 06 10:31:24 systemd-udevd[162]: enp2s0: sd-device-monitor: Passed 914 byte to netlink monitor
Line 10341: May 06 10:31:24 systemd-networkd[185]: enp2s0: Ignoring udev move event for device.

to the working case

Line 10604: May 06 10:39:48 systemd-udevd[150]: enp2s0: Device (SEQNUM=2384, ACTION=move) is queued
Line 10610: May 06 10:39:48 systemd-udevd[150]: enp2s0: sd-device-monitor: Passed 262 byte to netlink monitor
Line 10620: May 06 10:39:48 systemd-udevd[160]: enp2s0: Processing device (SEQNUM=2384, ACTION=move)
Line 10622: May 06 10:39:48 systemd-udevd[160]: enp2s0: IMPORT builtin 'net_id' /lib/udev/rules.d/75-net-description.rules:6
Line 10711: May 06 10:39:48 systemd-udevd[160]: enp2s0: IMPORT builtin 'hwdb' /lib/udev/rules.d/75-net-description.rules:12
Line 10725: May 06 10:39:48 systemd-udevd[160]: enp2s0: IMPORT builtin 'path_id' /lib/udev/rules.d/80-net-setup-link.rules:5
Line 10727: May 06 10:39:48 systemd-udevd[160]: enp2s0: sd-device: Created db file '/run/udev/data/n2' for '/devices/pci0000:00/0000:00:13.1/0000:02:00.0/net/enp2s0'
Line 10727: May 06 10:39:48 systemd-udevd[160]: enp2s0: sd-device: Created db file '/run/udev/data/n2' for '/devices/pci0000:00/0000:00:13.1/0000:02:00.0/net/enp2s0'
Line 10738: May 06 10:39:48 systemd-udevd[160]: enp2s0: Device (SEQNUM=2384, ACTION=move) processed
Line 10749: May 06 10:39:48 systemd-udevd[160]: enp2s0: sd-device-monitor: Passed 914 byte to netlink monitor
Line 12093: May 06 10:39:51 systemd-networkd[208]: enp2s0: New device has no master, continuing without
Line 12094: May 06 10:39:51 systemd-networkd[208]: enp2s0: Flags change: +MULTICAST +BROADCAST
Line 12095: May 06 10:39:51 systemd-networkd[208]: enp2s0: Link 2 added
Line 12096: May 06 10:39:51 systemd-networkd[208]: enp2s0: udev initialized link
Line 12097: May 06 10:39:51 systemd-networkd[208]: enp2s0: Saved original MTU: 1500
Line 12124: May 06 10:39:51 systemd-networkd[208]: enp2s0: Link state is up-to-date
Line 12125: May 06 10:39:51 systemd-networkd[208]: enp2s0: found matching network '/data/network_0/etc/systemd/network/enp2s0.network'
Line 12125: May 06 10:39:51 systemd-networkd[208]: enp2s0: found matching network '/data/network_0/etc/systemd/network/enp2s0.network'
Line 12126: May 06 10:39:51 systemd-networkd[208]: enp2s0: Setting address genmode for link
Line 12127: May 06 10:39:51 systemd-networkd[208]: enp2s0: Bringing link up
Line 12139: May 06 10:39:52 systemd-networkd[208]: enp2s0: Flags change: +UP +RUNNING
Line 12141: May 06 10:39:52 systemd-networkd[208]: enp2s0: Started LLDP.
Line 12243: May 06 10:39:52 systemd-networkd[208]: enp2s0: Flags change: -RUNNING
Line 12274: May 06 10:39:54 systemd-networkd[208]: enp2s0: Flags change: +LOWER_UP +RUNNING
Line 12276: May 06 10:39:54 systemd-networkd[208]: enp2s0: Gained carrier
Line 12277: May 06 10:39:54 systemd-networkd[208]: enp2s0: Acquiring DHCPv4 lease
Line 12289: May 06 10:39:54 systemd-networkd[208]: enp2s0: DHCPv4 address 192.168.0.17/24[http://192.168.0.17/24] via 192.168.0.1

Find the logs attached.

Thanks in advance,
Best regards
-------------- next part --------------
A non-text attachment was scrubbed...
Name: boot.error
Type: application/octet-stream
Size: 1169568 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/systemd-devel/attachments/20200507/463cf4e4/attachment-0002.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: boot.ok
Type: application/octet-stream
Size: 1163783 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/systemd-devel/attachments/20200507/463cf4e4/attachment-0003.obj>


More information about the systemd-devel mailing list