For me, the solution was to enable full event monitoring early in the boot process. On Debian 12 "bookworm":
# vi /usr/share/initramfs-tools/init
find the line where devtmpfs
is mounted on /dev
, and after that add a line to start udevadm monitor
in background:
mount -t devtmpfs -o nosuid,mode=0755 udev /dev
udevadm monitor -k -u -p > /dev/debug-udevadm-monitor.txt &
Then call update-initramfs -u
to get the change into /boot/initrd.img-xxxx
, and shutdown -r now
. After the restart, look in /dev/debug-udevadm-monitor.txt
for lines containing FAILED
or ERRNO
, or any other patterns related to the issue being debugged. In my case the problem event looked like this:
UDEV [2.582336] add /devices/pci0000:00/0000:00:19.0/net/eth4 (net)
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:19.0/net/eth4
SUBSYSTEM=net
INTERFACE=eth4
IFINDEX=4
SEQNUM=1518
USEC_INITIALIZED=1290728
ID_NET_NAMING_SCHEME=v252
ID_NET_NAME_MAC=enx00224d123456
ID_NET_NAME_ONBOARD=eno1
ID_NET_LABEL_ONBOARD=Intel(R) 82579V Gigabit Network Device
ID_NET_NAME_PATH=enp0s25
ID_BUS=pci
ID_VENDOR_ID=0x8086
ID_MODEL_ID=0x1503
ID_PATH=pci-0000:00:19.0
ID_PATH_TAG=pci-0000_00_19_0
ID_NET_DRIVER=e1000e
ID_NET_LINK_FILE=/usr/lib/systemd/network/99-default.link
ID_NET_NAME=eno1
ID_RENAMING=1
INTERFACE_OLD=eth2
UDEV_WORKER_FAILED=1
UDEV_WORKER_ERRNO=17
UDEV_WORKER_ERRNO_NAME=EEXIST
(that is, one cannot rename eth2 to eth4 because the latter already exists).
99-myrule.rules
... – jasonwryan May 04 '15 at 00:30systemd
change something to the normal udev behaviour? – Basj May 04 '15 at 00:38systemd
has it's own mounting capability: rules are proccessed lexcially, so yours is geting stomped. Also,RUN+=
will just block, useSYSTEMD_WANTS
instead; seeman systemd.device
. – jasonwryan May 04 '15 at 00:48udevadm monitor
, see this and this – Aquarius Power May 08 '15 at 20:42mount
should be in/bin/mount
– user.dz May 26 '15 at 20:20udevadm test
and validated rules against reality withudevadm info
. – zagrimsan Jun 02 '15 at 12:45