Bug#934589: udev: net.ifnames is wrongly imported as a property for any/all devices
quidame
quidame at poivron.org
Tue Aug 13 11:09:37 BST 2019
Hi,
On 12/08/2019 13:14, Michael Biebl wrote:
> Control: tags -1 + moreinfo unreproducible
To reproduce it, as said in the report, net.ifnames MUST BE SET in the
boot commandline.
$ cat /proc/cmdline
BOOT_IMAGE=/vmlinuz-4.19.0-5-amd64 root=/dev/mapper/luks-root ro
net.ifnames=0 quiet
The bug is fully reproducible on fresh installs of debian stable (udev
241-5), testing (udev 241-7) and sid (udev 241-7).
> I don't use LVM, but running that e.g. on /dev/sda5, I get
LVM doesn't matter here, as the property is imported to ALL devices,
including /dev/null !!! (as said in the report)
> What do you get if you run
> grep ifnames /etc/udev/rules.d/* /lib/udev/rules.d/*
I already did this before reporting the bug, and pointed to the first
line of /lib/udev/rules.d/73-usb-net-by-mac.rules, that is shipped with
the udev package:
IMPORT{cmdline}="net.ifnames"
As said in udev(7):
IMPORT{type}
Import a set of variables as device properties, depending on "type":
[...]
"cmdline"
Import a single property from the kernel command line. For
simple flags the value of the property is set to "1".
And again, for me the culprit is a missing block of filters **before**
this IMPORT directive,
> Can you tar up all files in /etc/udev/rules.d and /lib/udev/rules.d and
> attach it to this bug report.
My /etc/udev/rules.d is empty.
The only relevant file in /lib/udev/rules.d is 73-usb-net-by-mac.rules
(attached, unchanged)
Thanks,
quidame
-------------- next part --------------
# Use MAC based names for network interfaces which are directly or indirectly
# on USB and have an universally administered (stable) MAC address (second bit
# is 0). Don't do this when ifnames is disabled via kernel command line or
# customizing/disabling 99-default.link (or previously 80-net-setup-link.rules).
IMPORT{cmdline}="net.ifnames"
ENV{net.ifnames}=="0", GOTO="usb_net_by_mac_end"
ACTION=="add", SUBSYSTEM=="net", SUBSYSTEMS=="usb", NAME=="", \
ATTR{address}=="?[014589cd]:*", \
TEST!="/etc/udev/rules.d/80-net-setup-link.rules", \
TEST!="/etc/systemd/network/99-default.link", \
IMPORT{builtin}="net_id", NAME="$env{ID_NET_NAME_MAC}"
LABEL="usb_net_by_mac_end"
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <http://alioth-lists.debian.net/pipermail/pkg-systemd-maintainers/attachments/20190813/a7ec22a6/attachment.sig>
More information about the Pkg-systemd-maintainers
mailing list