我一直有这个问题,但相关答案都无法解决我的问题。我遇到的这个systemd-udevd
实例的资源消耗不断增加,直到笔记本电脑死机。
该问题似乎与具有以下 PCI ID 的 HP 设备有关03f0:0c51
,但我无法确定是哪种设备这是.dmesg
一遍又一遍地被下列数据轰炸:
$ dmesg
[ 667.720371] usb 1-2: new high-speed USB device number 50 using xhci_hcd
[ 667.883752] usb 1-2: New USB device found, idVendor=03f0, idProduct=0c51
[ 667.883754] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 667.883754] usb 1-2: Product: H380
[ 667.883755] usb 1-2: Manufacturer: HP
[ 667.883756] usb 1-2: SerialNumber: 003580023000167
[ 667.903096] cdc_mbim 1-2:1.0: bind() failure
[ 667.903604] cdc_acm 1-2:1.2: ttyACM0: USB ACM device
[ 667.904039] cdc_acm 1-2:1.4: ttyACM1: USB ACM device
[ 667.904510] cdc_acm 1-2:1.6: ttyACM2: USB ACM device
[ 667.908866] usb 1-2: USB disconnect, device number 50
[ 668.328363] usb 1-2: new high-speed USB device number 51 using xhci_hcd
[ 668.487939] usb 1-2: New USB device found, idVendor=03f0, idProduct=0c51
[ 668.487940] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 668.487941] usb 1-2: Product: H380
[ 668.487942] usb 1-2: Manufacturer: HP
[ 668.487943] usb 1-2: SerialNumber: 003580023000167
[ 668.507062] cdc_mbim 1-2:1.0: bind() failure
[ 668.507535] cdc_acm 1-2:1.2: ttyACM0: USB ACM device
[ 668.508086] cdc_acm 1-2:1.4: ttyACM1: USB ACM device
[ 668.508527] cdc_acm 1-2:1.6: ttyACM2: USB ACM device
[ 668.513128] usb 1-2: USB disconnect, device number 51
udevadm
还显示了不断添加和删除的设备:
$ udevadm monitor --udev
UDEV [910.996048] add /devices/pci0000:00/0000:00:14.0/usb1/1-2 (usb)
UDEV [911.002337] add /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.2 (usb)
UDEV [911.002462] add /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.1 (usb)
UDEV [911.002572] add /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.0 (usb)
UDEV [911.008984] add /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.4 (usb)
UDEV [911.009123] add /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.3 (usb)
UDEV [911.009234] add /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.5 (usb)
UDEV [911.009347] add /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.7 (usb)
UDEV [911.010646] remove /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.5 (usb)
UDEV [911.010771] add /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.6 (usb)
UDEV [911.010874] remove /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.7 (usb)
UDEV [911.014092] add /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.2/tty/ttyACM0 (tty)
UDEV [911.016825] remove /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.1 (usb)
UDEV [911.017042] add /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.8 (usb)
UDEV [911.017148] add /devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.4/tty/ttyACM1 (tty)
奇怪的是,该设备/sys/bus/usb/devices/1-2
似乎不存在,因为命令udevadm info --query=all /sys/bus/usb/devices/1-2
只是返回一个错误。lsusb
情况并没有好转,并且该设备只是不时地出现在结果中,但没有提供任何实际信息:
$ lsusb | ag 0c51
Bus 001 Device 047: ID 03f0:0c51 Hewlett-Packard
journalctl
提供以下输出:
Feb 20 16:39:11 MyLaptop kernel: usb 1-2: new high-speed USB device number 75 using xhci_hcd
Feb 20 16:39:12 MyLaptop systemd[4499]: dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device: Dev dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device appeare
Feb 20 16:39:12 MyLaptop systemd[2584]: dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device: Dev dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device appeare
Feb 20 16:39:12 MyLaptop systemd[1]: dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device: Dev dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device appeared t
Feb 20 16:39:12 MyLaptop kernel: usb 1-2: New USB device found, idVendor=03f0, idProduct=0c51
Feb 20 16:39:12 MyLaptop kernel: usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Feb 20 16:39:12 MyLaptop kernel: usb 1-2: Product: H380
Feb 20 16:39:12 MyLaptop kernel: usb 1-2: Manufacturer: HP
Feb 20 16:39:12 MyLaptop kernel: usb 1-2: SerialNumber: 003580023000167
Feb 20 16:39:12 MyLaptop kernel: cdc_mbim 1-2:1.0: bind() failure
Feb 20 16:39:12 MyLaptop kernel: cdc_acm 1-2:1.2: ttyACM0: USB ACM device
Feb 20 16:39:12 MyLaptop kernel: cdc_acm 1-2:1.4: ttyACM1: USB ACM device
Feb 20 16:39:12 MyLaptop kernel: cdc_acm 1-2:1.6: ttyACM2: USB ACM device
Feb 20 16:39:12 MyLaptop mtp-probe[11190]: checking bus 1, device 75: "/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2"
Feb 20 16:39:12 MyLaptop mtp-probe[11190]: bus: 1, device: 75 was not an MTP device
Feb 20 16:39:12 MyLaptop kernel: usb 1-2: USB disconnect, device number 75
Feb 20 16:39:12 MyLaptop kernel: usb 1-2: new high-speed USB device number 76 using xhci_hcd
Feb 20 16:39:12 MyLaptop systemd[4499]: dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device: Dev dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device appeare
Feb 20 16:39:12 MyLaptop systemd[1]: dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device: Dev dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device appeared t
Feb 20 16:39:12 MyLaptop systemd[1]: dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device: Dev dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device appeared t
Feb 20 16:39:12 MyLaptop systemd[2584]: dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device: Dev dev-serial-by\x2dpath-pci\x2d0000:00:14.0.device appeare
Feb 20 16:39:12 MyLaptop kernel: usb 1-2: New USB device found, idVendor=03f0, idProduct=0c51
Feb 20 16:39:12 MyLaptop kernel: usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Feb 20 16:39:12 MyLaptop kernel: usb 1-2: Product: H380
Feb 20 16:39:12 MyLaptop kernel: usb 1-2: Manufacturer: HP
Feb 20 16:39:12 MyLaptop kernel: usb 1-2: SerialNumber: 003580023000167
Feb 20 16:39:12 MyLaptop kernel: cdc_mbim 1-2:1.0: bind() failure
Feb 20 16:39:12 MyLaptop kernel: cdc_acm 1-2:1.2: ttyACM0: USB ACM device
Feb 20 16:39:12 MyLaptop kernel: cdc_acm 1-2:1.4: ttyACM1: USB ACM device
Feb 20 16:39:12 MyLaptop kernel: cdc_acm 1-2:1.6: ttyACM2: USB ACM device
Feb 20 16:39:12 MyLaptop kernel: usb 1-2: USB disconnect, device number 76
最后,我尝试检查systemd-udev
一下:
$ sudo /lib/systemd/systemd-udevd -D
IMPORT builtin 'usb_id' /lib/udev/rules.d/50-udev-default.rules:13
IMPORT builtin 'hwdb' /lib/udev/rules.d/50-udev-default.rules:13
IMPORT builtin 'hwdb' returned non-zero
MODE 0664 /lib/udev/rules.d/50-udev-default.rules:41
PROGRAM 'mtp-probe /sys/devices/pci0000:00/0000:00:14.0/usb1/1-2 1 27' /lib/udev/rules.d/69-libmtp.rules:1923
starting 'mtp-probe /sys/devices/pci0000:00/0000:00:14.0/usb1/1-2 1 27'
'mtp-probe /sys/devices/pci0000:00/0000:00:14.0/usb1/1-2 1 27'(out) '0'
Process 'mtp-probe /sys/devices/pci0000:00/0000:00:14.0/usb1/1-2 1 27' succeeded.
RUN '/lib/udev/tlp-usb-udev %p' /lib/udev/rules.d/85-tlp.rules:10
handling device node '/dev/bus/usb/001/026', devnum=c189:25, mode=0664, uid=0, gid=0
can not stat() node '/dev/bus/usb/001/026' (No such file or directory)
created db file '/run/udev/data/c189:25' for '/devices/pci0000:00/0000:00:14.0/usb1/1-2'
starting '/lib/udev/tlp-usb-udev /devices/pci0000:00/0000:00:14.0/usb1/1-2'
seq 33375 queued, 'remove' 'usb'
seq 33376 queued, 'remove' 'usb'
seq 33377 queued, 'remove' 'tty'
could not create device: Invalid argument
could not create device: Invalid argument
seq 33380 queued, 'remove' 'usb'
seq 33381 queued, 'remove' 'usb'
seq 33382 queued, 'remove' 'tty'
could not create device: Invalid argument
could not create device: Invalid argument
seq 33385 queued, 'remove' 'usb'
seq 33386 queued, 'remove' 'usb'
seq 33387 queued, 'remove' 'tty'
could not create device: Invalid argument
could not create device: Invalid argument
seq 33390 queued, 'remove' 'usb'
seq 33391 queued, 'remove' 'usb'
seq 33392 queued, 'remove' 'usb'
could not create device: Invalid argument
seq 33394 queued, 'remove' 'usb'
'/lib/udev/tlp-usb-udev /devices/pci0000:00/0000:00:14.0/usb1/1-2'(err) 'cat: '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/busnum': No such file or directory'
'/lib/udev/tlp-usb-udev /devices/pci0000:00/0000:00:14.0/usb1/1-2'(err) 'cat: '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/devnum''
'/lib/udev/tlp-usb-udev /devices/pci0000:00/0000:00:14.0/usb1/1-2'(err) ': No such file or directory'
'/lib/udev/tlp-usb-udev /devices/pci0000:00/0000:00:14.0/usb1/1-2'(err) 'cat: '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/idVendor': No such file or directory'
'/lib/udev/tlp-usb-udev /devices/pci0000:00/0000:00:14.0/usb1/1-2'(err) 'cat: '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/power/level': No such file or directory'
'/lib/udev/tlp-usb-udev /devices/pci0000:00/0000:00:14.0/usb1/1-2'(err) '/lib/udev/tlp-usb-udev: 127: /lib/udev/tlp-usb-udev: '
'/lib/udev/tlp-usb-udev /devices/pci0000:00/0000:00:14.0/usb1/1-2'(err) 'cannot create /sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/power/level: Directory nonexistent'
Process '/lib/udev/tlp-usb-udev /devices/pci0000:00/0000:00:14.0/usb1/1-2' succeeded.
passed device to netlink monitor 0x556d95dd0ed0
seq 33315 processed
passed 295 byte device to netlink monitor 0x556d95dfe9e0
passed 295 byte device to netlink monitor 0x556d95dfe9e0
passed 294 byte device to netlink monitor 0x556d95dfe9e0
passed 310 byte device to netlink monitor 0x556d95dfe9e0
seq 33318 running
seq 33321 running
passed 294 byte device to netlink monitor 0x556d95dfe9e0
passed 310 byte device to netlink monitor 0x556d95dfe9e0
passed 294 byte device to netlink monitor 0x556d95dfe9e0
passed 310 byte device to netlink monitor 0x556d95dfe9e0seq 33328 running
passed 296 byte device to netlink monitor 0x556d95dfe9e0
seq 33317 running
value '[dmi/id]sys_vendor' is 'HP'seq 33331 runningvalue '[dmi/id]sys_vendor' is 'HP'
value '[dmi/id]sys_vendor' is 'HP'
seq 33326 running
value '[dmi/id]sys_vendor' is 'HP'
value '[dmi/id]sys_vendor' is 'HP'IMPORT builtin 'hwdb' /lib/udev/rules.d/50-udev-default.rules:15
value '[dmi/id]sys_vendor' is 'HP'
value '[dmi/id]sys_vendor' is 'HP'
value '[dmi/id]sys_vendor' is 'HP'
IMPORT builtin 'hwdb' /lib/udev/rules.d/50-udev-default.rules:15
value '[dmi/id]sys_vendor' is 'HP'
IMPORT builtin 'hwdb' /lib/udev/rules.d/50-udev-default.rules:15
value '[dmi/id]sys_vendor' is 'HP'
IMPORT builtin 'hwdb' /lib/udev/rules.d/50-udev-default.rules:15
IMPORT builtin 'usb_id' /lib/udev/rules.d/60-libgphoto2-6.rules:9
IMPORT builtin 'usb_id' /lib/udev/rules.d/60-libgphoto2-6.rules:9
unable to access usb_interface device of '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.6'
IMPORT builtin 'usb_id' returned non-zero
IMPORT builtin 'usb_id' /lib/udev/rules.d/60-libgphoto2-6.rules:9IMPORT builtin 'usb_id' /lib/udev/rules.d/60-libgphoto2-6.rules:9
unable to access usb_interface device of '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.1'
IMPORT builtin 'usb_id' returned non-zero
unable to access usb_interface device of '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.5'
IMPORT builtin 'usb_id' returned non-zero
seq 33333 runningRUN 'kmod load $env{MODALIAS}' /lib/udev/rules.d/80-drivers.rules:5
RUN 'kmod load $env{MODALIAS}' /lib/udev/rules.d/80-drivers.rules:5
created db file '/run/udev/data/+usb:1-2:1.6' for '/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.6'
Execute 'load' 'usb:v03F0p0C51d1729dcEFdsc02dp01ic02isc02ip00in06'
RUN 'kmod load $env{MODALIAS}' /lib/udev/rules.d/80-drivers.rules:5
created db file '/run/udev/data/+usb:1-2:1.1' for '/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.1'
Execute 'load' 'usb:v03F0p0C51d1729dcEFdsc02dp01ic0Aisc00ip02in01'
created db file '/run/udev/data/+usb:1-2:1.5' for '/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.5'Inserted 'cdc_acm'
Execute 'load' 'usb:v03F0p0C51d1729dcEFdsc02dp01ic0Aisc00ip00in05'
value '[dmi/id]sys_vendor' is 'HP'
No module matches 'usb:v03F0p0C51d1729dcEFdsc02dp01ic0Aisc00ip02in01'
passed device to netlink monitor 0x556d95dc7960
seq 33328 processed
value '[dmi/id]sys_vendor' is 'HP'No module matches 'usb:v03F0p0C51d1729dcEFdsc02dp01ic0Aisc00ip00in05'
passed device to netlink monitor 0x556d95dd0ed0
seq 33317 processed
IMPORT builtin 'hwdb' /lib/udev/rules.d/50-udev-default.rules:15
passed device to netlink monitor 0x556d95dfc080
seq 33326 processed
value '[dmi/id]sys_vendor' is 'HP'
passed 214 byte device to netlink monitor 0x556d95dfe9e0
IMPORT builtin 'hwdb' /lib/udev/rules.d/50-udev-default.rules:15
passed 298 byte device to netlink monitor 0x556d95dfe9e0
passed 298 byte device to netlink monitor 0x556d95dfe9e0
seq 33329 running
IMPORT builtin 'usb_id' /lib/udev/rules.d/60-libgphoto2-6.rules:9
seq 33346 running
value '[dmi/id]sys_vendor' is 'HP'
unable to access usb_interface device of '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.2'
IMPORT builtin 'usb_id' returned non-zero
seq 33336 running
IMPORT builtin 'usb_id' /lib/udev/rules.d/60-libgphoto2-6.rules:9value '[dmi/id]sys_vendor' is 'HP'
GROUP 20 /lib/udev/rules.d/50-udev-default.rules:26
value '[dmi/id]sys_vendor' is 'HP'
unable to access usb_interface device of '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.8'value '[dmi/id]sys_vendor' is 'HP'
IMPORT builtin 'usb_id' returned non-zero
value '[dmi/id]sys_vendor' is 'HP'
value '[dmi/id]sys_vendor' is 'HP'
RUN 'kmod load $env{MODALIAS}' /lib/udev/rules.d/80-drivers.rules:5
IMPORT builtin 'hwdb' /lib/udev/rules.d/60-serial.rules:7
created db file '/run/udev/data/+usb:1-2:1.2' for '/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.2'
Execute 'load' 'usb:v03F0p0C51d1729dcEFdsc02dp01ic02isc02ip01in02'
Inserted 'cdc_acm'
IMPORT builtin 'usb_id' /lib/udev/rules.d/60-serial.rules:8
RUN 'kmod load $env{MODALIAS}' /lib/udev/rules.d/80-drivers.rules:5
passed device to netlink monitor 0x556d95dfc080unable to access usb_interface device of '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.6/tty/ttyACM2'
seq 33336 processed
IMPORT builtin 'usb_id' returned non-zero
seq 33316 running
created db file '/run/udev/data/+usb:1-2:1.8' for '/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.8'
Execute 'load' 'usb:v03F0p0C51d1729dcEFdsc02dp01icFFisc01ip00in08'
value '[dmi/id]sys_vendor' is 'HP'
IMPORT builtin 'hwdb' /lib/udev/rules.d/50-udev-default.rules:15
No module matches 'usb:v03F0p0C51d1729dcEFdsc02dp01icFFisc01ip00in08'
passed device to netlink monitor 0x556d95dc7960
seq 33346 processed
passed device to netlink monitor 0x556d95dfbc90
seq 33333 processed
passed 299 byte device to netlink monitor 0x556d95dfe9e0
value '[dmi/id]sys_vendor' is 'HP'
unable to access usb_interface device of '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.7'
IMPORT builtin 'usb_id' returned non-zero
value '[dmi/id]sys_vendor' is 'HP'RUN 'kmod load $env{MODALIAS}' /lib/udev/rules.d/80-drivers.rules:5
IMPORT builtin 'hwdb' /lib/udev/rules.d/50-udev-default.rules:15
created db file '/run/udev/data/+usb:1-2:1.7' for '/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.7'
Execute 'load' 'usb:v03F0p0C51d1729dcEFdsc02dp01ic0Aisc00ip00in07'
No module matches 'usb:v03F0p0C51d1729dcEFdsc02dp01ic0Aisc00ip00in07'
passed device to netlink monitor 0x556d95dbd440
seq 33331 processed
IMPORT builtin 'usb_id' /lib/udev/rules.d/60-libgphoto2-6.rules:9IMPORT builtin 'usb_id' /lib/udev/rules.d/60-libgphoto2-6.rules:9
passed 298 byte device to netlink monitor 0x556d95dfe9e0
unable to access usb_interface device of '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.3'
IMPORT builtin 'usb_id' returned non-zero
unable to access usb_interface device of '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.0'
IMPORT builtin 'usb_id' returned non-zero
passed device to netlink monitor 0x556d95dfc470
seq 33318 processed
passed 214 byte device to netlink monitor 0x556d95dfe9e0
基本上是一遍又一遍地重复同样的信息。
我尝试添加以下规则:
SUBSYSTEM="usb", ATTR{idVendor}=="03f0", ATTR{idProduct}=="0c51", OPTIONS+="ignore_device", OPTIONS+="last_rule"
SUBSYSTEM="usb", ATTR{idVendor}=="03f0", ATTR{idProduct}=="0c51", ATTR{authorized}="0"
但它们似乎也不起作用。知道我下一步该怎么做吗?
答案1
我在 HP 笔记本电脑上遇到了同样的问题,我的机器 idVendor 03f0 和 idProduct 0c51 是无线广域网(WWAN):https://support.hp.com/nz-en/document/c04221330
我可以在以下位置禁用它:BIOS/UEFI -> 高级 -> 内置设备选项 -> 移动网络设备 (WWAN)
此后,dmesg 垃圾邮件停止,其他 USB 设备开始正常工作(以前我必须在启动 HP 笔记本电脑之前插入 USB 设备)。