29

I recently switched from Kubuntu 17.10 to Kubuntu 18.04 (fresh installed). The problem is the process systemd-udevd is constantly running and consuming 90-100% CPU load. After tinkering around with all devices I found out that it is because of WiFi! Once I turn on WiFi the process starts running and CPU load goes up to 100%. But whenever I turn off the WiFi it gets down to zero! here is the top results when WiFi is on:

  PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND                                                           
  338 root      20   0   94336  51744   3120 S  44.7  0.6   0:35.50 systemd-udevd                                                     
  24957 root    20   0   67936  25248   2860 R  40.4  0.3   0:23.85 systemd-udevd                                                     
  328 root      19  -1  150720  53068  52264 S   4.3  0.7   0:07.61 systemd-journal

and running: strace -p 338 makes the following output repeatedly:

strace: Process 338 attached
strace: [ Process PID=338 runs in x32 mode. ]
strace: [ Process PID=338 runs in 64 bit mode. ]
epoll_wait(10, [{EPOLLIN, {u32=4010170080, u64=94544830289632}}, {EPOLLIN, {u32=4010060672, u64=94544830180224}}], 11, 0) = 2
clock_gettime(CLOCK_REALTIME, {tv_sec=1524848329, tv_nsec=484799898}) = 0
clock_gettime(CLOCK_MONOTONIC, {tv_sec=1045, tv_nsec=112300760}) = 0
clock_gettime(CLOCK_BOOTTIME, {tv_sec=1045, tv_nsec=112454363}) = 0
epoll_wait(10, [{EPOLLIN, {u32=4010170080, u64=94544830289632}}, {EPOLLIN, {u32=4010060672, u64=94544830180224}}], 11, 0) = 2
clock_gettime(CLOCK_REALTIME, {tv_sec=1524848329, tv_nsec=485376240}) = 0
clock_gettime(CLOCK_MONOTONIC, {tv_sec=1045, tv_nsec=112893238}) = 0
clock_gettime(CLOCK_BOOTTIME, {tv_sec=1045, tv_nsec=113047679}) = 0
recvmsg(7, {msg_name=NULL, msg_namelen=0, msg_iov=[{iov_base="", iov_len=0}], msg_iovlen=1, msg_control=[{cmsg_len=28, cmsg_level=SOL_SOCKET, cmsg_type=SCM_CREDENTIALS, cmsg_data={pid=24957, uid=0, gid=0}}], msg_controllen=32, msg_flags=0}, MSG_DONTWAIT) = 0
recvmsg(7, {msg_namelen=0}, MSG_DONTWAIT) = -1 EAGAIN (Resource temporarily unavailable)
sendmsg(3, {msg_name={sa_family=AF_NETLINK, nl_pid=-853365251, nl_groups=00000000}, msg_namelen=12, msg_iov=[{iov_base="libudev\0\376\355\312\376(\0\0\0(\0\0\0\315\0\0\0\5w\305\345\261\2Ge"..., iov_len=40}, {iov_base="ACTION=unbind\0DEVPATH=/devices/p"..., iov_len=205}], msg_iovlen=2, msg_controllen=0, msg_flags=0}, 0) = 245
epoll_wait(10, [{EPOLLIN, {u32=4010170080, u64=94544830289632}}], 11, 0) = 1
clock_gettime(CLOCK_REALTIME, {tv_sec=1524848329, tv_nsec=495431807}) = 0
clock_gettime(CLOCK_MONOTONIC, {tv_sec=1045, tv_nsec=123814890}) = 0
clock_gettime(CLOCK_BOOTTIME, {tv_sec=1045, tv_nsec=123945023}) = 0
recvmsg(3, {msg_name={sa_family=AF_NETLINK, nl_pid=0, nl_groups=0x000001}, msg_namelen=128->12, msg_iov=[{iov_base="unbind@/devices/pci0000:00/0000:"..., iov_len=8192}], msg_iovlen=1, msg_control=[{cmsg_len=28, cmsg_level=SOL_SOCKET, cmsg_type=SCM_CREDENTIALS, cmsg_data={pid=0, uid=0, gid=0}}], msg_controllen=32, msg_flags=0}, 0) = 243
getrandom("\x9c\x6d\x41\x2b\xb5\xf0\xf1\x9a\x32\xb3\x4a\x73\xee\x04\xff\x90", 16, GRND_NONBLOCK) = 16
clock_gettime(CLOCK_MONOTONIC, {tv_sec=1045, tv_nsec=126971116}) = 0
getrandom("\xaf\x35\x7a\x36\x01\x32\xa6\xe6\x13\x46\x4e\x22\xcc\x48\x77\x9b", 16, GRND_NONBLOCK) = 16
getrandom("\x48\x0b\xeb\xf1\xf0\x1c\xf1\x78\x89\xb7\x48\xe1\x84\x38\xc9\x3c", 16, GRND_NONBLOCK) = 16
getrandom("\x11\x06\x8c\x4a\xeb\xff\x84\x8e\x0c\x09\x00\x84\x62\x74\xfc\xd7", 16, GRND_NONBLOCK) = 16
getrandom("\xb5\x8e\x19\x16\xad\xf6\x16\x7e\x21\x66\x90\x12\x2d\x43\x46\x45", 16, GRND_NONBLOCK) = 16
getrandom("\x84\x7d\x47\x96\x50\x36\xad\x28\x06\x6e\xed\x33\xe0\x05\x57\x20", 16, GRND_NONBLOCK) = 16
epoll_wait(10, [{EPOLLIN, {u32=4010170080, u64=94544830289632}}, {EPOLLIN, {u32=4010060672, u64=94544830180224}}], 11, 0) = 2
clock_gettime(CLOCK_REALTIME, {tv_sec=1524848329, tv_nsec=504542288}) = 0
clock_gettime(CLOCK_MONOTONIC, {tv_sec=1045, tv_nsec=131992368}) = 0
clock_gettime(CLOCK_BOOTTIME, {tv_sec=1045, tv_nsec=132096027}) = 0
epoll_wait(10, [{EPOLLIN, {u32=4010170080, u64=94544830289632}}, {EPOLLIN, {u32=4010060672, u64=94544830180224}}], 11, 0) = 2
clock_gettime(CLOCK_REALTIME, {tv_sec=1524848329, tv_nsec=504955877}) = 0
clock_gettime(CLOCK_MONOTONIC, {tv_sec=1045, tv_nsec=132438717}) = 0
clock_gettime(CLOCK_BOOTTIME, {tv_sec=1045, tv_nsec=132555928}) = 0
recvmsg(7, {msg_name=NULL, msg_namelen=0, msg_iov=[{iov_base="", iov_len=0}], msg_iovlen=1, msg_control=[{cmsg_len=28, cmsg_level=SOL_SOCKET, cmsg_type=SCM_CREDENTIALS, cmsg_data={pid=24957, uid=0, gid=0}}], msg_controllen=32, msg_flags=0}, MSG_DONTWAIT) = 0
recvmsg(7, {msg_namelen=0}, MSG_DONTWAIT) = -1 EAGAIN (Resource temporarily unavailable)
sendmsg(3, {msg_name={sa_family=AF_NETLINK, nl_pid=-853365251, nl_groups=00000000}, msg_namelen=12, msg_iov=[{iov_base="libudev\0\376\355\312\376(\0\0\0(\0\0\0\23\1\0\0\5w\305\345\261\2Ge"..., iov_len=40}, {iov_base="ACTION=bind\0DEVPATH=/devices/pci"..., iov_len=275}], msg_iovlen=2, msg_controllen=0, msg_flags=0}, 0) = 315
epoll_wait(10, [{EPOLLIN, {u32=4010170080, u64=94544830289632}}], 11, 0) = 1
clock_gettime(CLOCK_REALTIME, {tv_sec=1524848329, tv_nsec=512870505}) = 0
clock_gettime(CLOCK_MONOTONIC, {tv_sec=1045, tv_nsec=140367037}) = 0
clock_gettime(CLOCK_BOOTTIME, {tv_sec=1045, tv_nsec=140494166}) = 0
recvmsg(3, {msg_name={sa_family=AF_NETLINK, nl_pid=0, nl_groups=0x000001}, msg_namelen=128->12, msg_iov=[{iov_base="bind@/devices/pci0000:00/0000:00"..., iov_len=8192}], msg_iovlen=1, msg_control=[{cmsg_len=28, cmsg_level=SOL_SOCKET, cmsg_type=SCM_CREDENTIALS, cmsg_data={pid=0, uid=0, gid=0}}], msg_controllen=32, msg_flags=0}, 0) = 311
getrandom("\x21\xcd\x52\xae\x20\xa4\xe9\x0f\x2c\x3f\x68\x8a\x77\x65\xfb\x22", 16, GRND_NONBLOCK) = 16
getrandom("\xb5\x1f\x43\xf7\x14\x3e\x29\x6c\xdd\x95\xd5\x64\xec\xec\x66\xca", 16, GRND_NONBLOCK) = 16
clock_gettime(CLOCK_MONOTONIC, {tv_sec=1045, tv_nsec=141295429}) = 0
getrandom("\xe7\x73\x2e\xc2\x5d\x71\x93\x8a\xd0\xf4\x5f\xd7\x91\x1f\x7b\x00", 16, GRND_NONBLOCK) = 16
getrandom("\xe4\xd4\xd3\x2c\xa2\xa1\x0c\x96\x6e\x6a\x34\x9c\x50\x06\x3d\x43", 16, GRND_NONBLOCK) = 16
getrandom("\xb0\x7f\xf7\x93\x1f\xa6\x6d\x2e\x01\xfb\x21\x97\x4b\xe8\x85\x14", 16, GRND_NONBLOCK) = 16
getrandom("\x3f\x94\x2b\x17\x01\x8f\x88\x2e\x08\xa0\x9d\xd0\xef\x4f\x0e\x9a", 16, GRND_NONBLOCK) = 16
epoll_wait(10, [{EPOLLIN, {u32=4010170080, u64=94544830289632}}, {EPOLLIN, {u32=4010060672, u64=94544830180224}}], 11, 0) = 2
clock_gettime(CLOCK_REALTIME, {tv_sec=1524848329, tv_nsec=519062044}) = 0
clock_gettime(CLOCK_MONOTONIC, {tv_sec=1045, tv_nsec=146474265}) = 0
clock_gettime(CLOCK_BOOTTIME, {tv_sec=1045, tv_nsec=146513033}) = 0
epoll_wait(10, [{EPOLLIN, {u32=4010170080, u64=94544830289632}}, {EPOLLIN, {u32=4010060672, u64=94544830180224}}], 11, 0) = 2
clock_gettime(CLOCK_REALTIME, {tv_sec=1524848329, tv_nsec=519231922}) = 0
clock_gettime(CLOCK_MONOTONIC, {tv_sec=1045, tv_nsec=146636530}) = 0
clock_gettime(CLOCK_BOOTTIME, {tv_sec=1045, tv_nsec=146675297}) = 0
recvmsg(7, {msg_name=NULL, msg_namelen=0, msg_iov=[{iov_base="", iov_len=0}], msg_iovlen=1, msg_control=[{cmsg_len=28, cmsg_level=SOL_SOCKET, cmsg_type=SCM_CREDENTIALS, cmsg_data={pid=24957, uid=0, gid=0}}], msg_controllen=32, msg_flags=0}, MSG_DONTWAIT) = 0
recvmsg(7, {msg_namelen=0}, MSG_DONTWAIT) = -1 EAGAIN (Resource temporarily unavailable)
sendmsg(3, {msg_name={sa_family=AF_NETLINK, nl_pid=-853365251, nl_groups=00000000}, msg_namelen=12, msg_iov=[{iov_base="libudev\0\376\355\312\376(\0\0\0(\0\0\0\315\0\0\0\5w\305\345\261\2Ge"..., iov_len=40}, {iov_base="ACTION=unbind\0DEVPATH=/devices/p"..., iov_len=205}], msg_iovlen=2, msg_controllen=0, msg_flags=0}, 0) = 245
epoll_wait(10, [{EPOLLIN, {u32=4010170080, u64=94544830289632}}], 11, 0) = 1
clock_gettime(CLOCK_REALTIME, {tv_sec=1524848329, tv_nsec=525080911}) = 0
clock_gettime(CLOCK_MONOTONIC, {tv_sec=1045, tv_nsec=152528058}) = 0
clock_gettime(CLOCK_BOOTTIME, {tv_sec=1045, tv_nsec=152611810}) = 0
....

running udevadm monitor prints the following repeatedly:

KERNEL[1464.842652] bind     /devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0 (usb)
KERNEL[1464.844393] unbind   /devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0 (usb)
UDEV  [1464.845340] bind     /devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0 (usb)
KERNEL[1464.857728] bind     /devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0 (usb)
KERNEL[1464.858361] unbind   /devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0 (usb)
....

and running journalctl returns repeatedly:

Apr 27 05:22:09 amir-pc systemd-udevd[359]: Process 'hid2hci --method=dell --devpath=/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3
Apr 27 05:22:09 amir-pc upowerd[1339]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0
-- Logs begin at Fri 2018-04-27 05:22:09 +0430, end at Fri 2018-04-27 21:37:15 +0430. --
Apr 27 05:22:09 amir-pc systemd-udevd[359]: Process 'hid2hci --method=dell --devpath=/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3
Apr 27 05:22:09 amir-pc upowerd[1339]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0
Apr 27 05:22:09 amir-pc systemd-udevd[359]: Process 'hid2hci --method=dell --devpath=/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3
Apr 27 05:22:09 amir-pc upowerd[1339]: unhandled action 'bind' on /sys/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0
....

running dmesg returns:

[  441.582359] usb 3-1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[  441.582361] usb 3-1.3: Product: Dell Wireless 370 Bluetooth Mini-card
[  441.582363] usb 3-1.3: Manufacturer: Dell Computer Corp
[  450.803644] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.811642] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.819653] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.826650] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.833668] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.841644] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.848630] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.856628] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.863632] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.871611] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.881629] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.888616] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.896634] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.903596] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.910611] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.917595] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.926603] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.933598] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.942616] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.949606] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.957363] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.964607] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.973581] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.980582] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.987582] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  450.994561] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  451.004574] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  451.009525] ERROR @wl_cfg80211_scan : 
[  451.009527] WLC_SCAN error (-22)
[  451.010550] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71
[  451.020078] usb 3-1: USB disconnect, device number 14
[  451.020081] usb 3-1.1: USB disconnect, device number 15
[  451.076974] usb 3-1.2: USB disconnect, device number 16
[  451.077105] usb 3-1.3: USB disconnect, device number 19
[  796.468102] usb 3-1: new full-speed USB device number 20 using uhci_hcd
[  796.672318] usb 3-1: New USB device found, idVendor=0a5c, idProduct=4500
[  796.672322] usb 3-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[  796.672325] usb 3-1: Product: BCM2046B1
[  796.672328] usb 3-1: Manufacturer: Broadcom
[  796.674239] hub 3-1:1.0: USB hub found
[  796.676385] hub 3-1:1.0: 3 ports detected
[  796.976059] usb 3-1.1: new full-speed USB device number 21 using uhci_hcd
[  797.109323] usb 3-1.1: New USB device found, idVendor=413c, idProduct=8157
[  797.109332] usb 3-1.1: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[  797.116785] input: HID 413c:8157 as /devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.1/3-1.1:1.0/0003:413C:8157.000B/input/input25
[  797.176461] hid-generic 0003:413C:8157.000B: input,hidraw0: USB HID v1.11 Keyboard [HID 413c:8157] on usb-0000:00:1a.0-1.1/input0
[  797.256314] usb 3-1.2: new full-speed USB device number 22 using uhci_hcd
[  797.396307] usb 3-1.2: New USB device found, idVendor=413c, idProduct=8158
[  797.396315] usb 3-1.2: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[  797.405072] input: HID 413c:8158 as /devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0/0003:413C:8158.000C/input/input26
[  797.464858] hid-generic 0003:413C:8158.000C: input,hidraw3: USB HID v1.11 Mouse [HID 413c:8158] on usb-0000:00:1a.0-1.2/input0
[  797.564507] IPv6: ADDRCONF(NETDEV_UP): wlp4s0: link is not ready
[  797.944045] usb 3-1.3: new full-speed USB device number 23 using uhci_hcd
[  803.296508] usb 3-1.3: unable to read config index 0 descriptor/all
[  803.296515] usb 3-1.3: can't read configurations, error -110
[  803.376039] usb 3-1.3: new full-speed USB device number 24 using uhci_hcd
[  808.672986] usb 3-1.3: unable to read config index 0 descriptor/all
[  808.672993] usb 3-1.3: can't read configurations, error -110
[  808.673984] usb 3-1-port3: attempt power cycle
[  809.280029] usb 3-1.3: new full-speed USB device number 25 using uhci_hcd
[  809.340944] usb 3-1.3: New USB device found, idVendor=413c, idProduct=8156
[  809.340948] usb 3-1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[  809.340951] usb 3-1.3: Product: Dell Wireless 370 Bluetooth Mini-card
[  809.340954] usb 3-1.3: Manufacturer: Dell Computer Corp
[ 1337.985097] perf: interrupt took too long (2508 > 2500), lowering kernel.perf_event_max_sample_rate to 79500
[ 1387.269440] perf: interrupt took too long (3140 > 3135), lowering kernel.perf_event_max_sample_rate to 63500
[ 1454.553305] perf: interrupt took too long (3927 > 3925), lowering kernel.perf_event_max_sample_rate to 50750
....

and running /lib/systemd/systemd-udevd -D returns below results repeatedly:

IMPORT builtin 'hwdb' /lib/udev/rules.d/50-udev-default.rules:14
RUN 'hid2hci --method=dell --devpath=%p' /lib/udev/rules.d/97-hid2hci.rules:11
starting 'hid2hci --method=dell --devpath=/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0'
seq 284188 queued, 'bind' 'usb'
seq 284189 queued, 'unbind' 'usb'
'hid2hci --method=dell --devpath=/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0'(err) 'error: switching device '/sys//devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0' failed.'
Process 'hid2hci --method=dell --devpath=/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0' failed with exit code 1.
seq 284184 processed
seq 284185 running
RUN 'hid2hci --method=dell --devpath=%p' /lib/udev/rules.d/97-hid2hci.rules:11
starting 'hid2hci --method=dell --devpath=/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.2/3-1.2:1.0'
seq 284190 queued, 'bind' 'usb'
seq 284191 queued, 'unbind' 'usb'

My fresh installed Kubuntu is using kernel version 4.15.0-20-generic and my laptop is a Dell Studio XPS 1640. WiFi is using bcmwl-kernel-source 6.30.223.271+bdcom-0ubuntu4 driver (downgrading to a previous working driver didn't solve the problem).

It's worth mentioning that no USB devices are connected, only a wireless mouse, which makes no problem (disconnecting it doesn't affect the problem). But as mentioned turning off WiFi always make the high CPU load disappear.

24

I installed Ubuntu 18.04 LTS (AMD64) on my Dell XPS Studio 1340 and I was suffering the same issue. I've solved it by completely disabling Bluetooth from the BIOS. I know it isn't a solution but a workaround, but it works for me because I rarely use Bluetooth.

It looks like a bug in the kernel or systemd without a fix yet:

| improve this answer | |
  • Unfortunately i had to downgrade to 17.10 because of some conflicts in php and mysql libraries so i can't test the suggestions. But it seems that the proposed solution solves the problem. So i accept it as the correct answer. Thanks for the input. – Firouziam May 1 '18 at 12:25
  • I reinstalled kubuntu 18.04 to test it out. It works perfectly and now cpu fan is sleeping like a baby! Thanks for the suggestions. – Firouziam May 3 '18 at 23:41
  • 1
    Experienced the same thing on Dell Inspiron. It's affecting Kali Linux Rolling too :( – Neo Elit Jul 23 '18 at 11:23
  • Disabling bluetooth fixed this issue for my Precision M4400 running OpenSUSE (kernel 4.17.14). Thanks! – helrich Aug 19 '18 at 14:03
26

Here's a workaround:

Immediately after booting, run the following commands:

sudo systemctl stop systemd-udevd systemd-udevd-kernel.socket systemd-udevd-control.socket
sudo systemctl start systemd-udevd systemd-udevd-kernel.socket systemd-udevd-control.socket

It worked on my Dell laptop.

| improve this answer | |
  • Confirmed this worked for me as well. In my case the error was not related to bluetooth, but some nvidia card thing that was performed repeatedly. – astrojuanlu Oct 18 '18 at 14:27
  • As I understand, before all hardware is discovered properly, bind/unbind start executing when no procedures are available and it does not get reinitialized. After stopping and starting, it gets all the procedures in place. Probably, it is booting sequence problem. – Y S Gupta Nov 20 '18 at 10:45
  • I got similar problem after hardware change (physically removed nvidia graphics card). Looks like the trick helped, at least temporarily. – Mekk Jan 31 at 20:00
  • … (after card removal systemd-udevd stayed at 100% cpu andkern.log flood with errors like "NVRM: No NVIDIA graphics adapter found!" and few similar emitted in hundreds per second). Looks like the trick offered in this comment helped, at least temporarily. – Mekk Jan 31 at 20:09
5

As stated already in the previous answers, it's related to not the best one Dell Wireless 370 Bluetooth and I've been also affected by it with my Dell Studio XPS 1645.

Not only the bluetooth support has worked badly for a couple of years, now there is that new problem in kernel drivers affecting CPU usage.

I would just add that instead of removing /lib/udev/rules.d/97-hid2hci.rules file it's better to create an empty file instead:

touch /etc/udev/rules.d/97-hid2hci.rules

That will guarantee the issue not to reappear after bluez package update.

On a side note, I've finished with buying a bluetooth dongle for a pound or two on ebay but I'd rather have the laptop working as expected, of course.

| improve this answer | |
  • Thanks. There must have been a bluez update for ubuntu 18.04 this week, as the CPU issue returned, as did this rules file. I'll create the dummy file as you suggest. – user795750 Jul 14 '18 at 0:18
5

I think I've figured out the answer.

Run

/lib/systemd/systemd-udevd -D

should print garbage in endless loop containing ".../97-hid2hci.rules:"

If so, edit /lib/udev/rules.d/97-hid2hci.rules

and add

ACTION=="add" 

in front of line mentioned by above command.

It should be something like this (I'm using fedora 28, but the problem looked identical):

ACTION=="add", ATTR{bInterfaceClass}=="03", ATTR{bInterfaceSubClass}=="01", ATTR{bInterfaceProtocol}=="02", \
  ATTRS{bDeviceClass}=="00", ATTRS{idVendor}=="413c", ATTRS{bmAttributes}=="e0", \
  RUN+="hid2hci --method=dell --devpath=%p", ENV{HID2HCI_SWITCH}="1"

With above fix, everything works perfect on my old Dell. Hope that helps ;)

| improve this answer | |
  • I can confirm this works partially on a Latitude E5500. The high CPU usage is gone and BT can actually be toggled in the settings. The weird thing is that even though BT is clearly on (blue indicator lights up, and the machine is discoverable), the settings menu insists that BT is off, so no devices can be paired. – petkov.np Aug 21 '18 at 17:08
  • Alright, this fixed the issue. But may I know what exactly adding ACTION=="add" does? – rootkea Apr 17 '19 at 8:30
5

In my case, this issue was due to bluez. Open Synaptic package manager and search for bluez, and uninstall it. Your problem will be solved.

| improve this answer | |
4

I am in the process of upgrading a dell studio 1737 from Ubuntu 16.04 to 18.04 and found an answer to a similar problem.

My system is quite old and cannot tolerate at being at 100% CPU for more than a few minutes before shutting down, so I've not even seen the 18.04 login screen yet. This has been a difficult process!

ctrl+alt+f2 gave me a terminal login, and top revealed systemd-udevd was at 100% CPU.

less /var/log/syslog

showed

Process 'hid2hci --method=dell failed

over and over again.

hid2hci is a bluetooth process and BT is not something I need and it was disabled. Curious.

My immediate goal was to get longer access to this computer. No doubt an expert will eventually come up with the proper solution, but I found this post on the Manjaro forums

I found the problem went away after removing /lib/udev/rules.d/97-hid2hci.rules (provided by the bluez package) The devices they refer there include the Dell touchpad… I have no idea what the touchpad has to do with bluetooth or why bluez is configuring them.

So I mv'd /lib/udev/rules.d/97-hid2hci.rules... and after a reboot, sytemd-udevd is now well behaved.

This can only be thought of as a temporary solution, and I do not know if this change will impact on wifi or the touchpad (I use neither), or create other problems, but I'm in a much position than I was a few hours ago!

| improve this answer | |
0

The Bluetooth application on your device or any device really is the same as your phone, you must have previously installed a 3rd party application or upgraded the application bluez which handles Bluetooth devices... So after a reboot it triggered the Bluetooth software to discover any in-range Bluetooth devices, and none were found so it reiterates... At least in my opinion it seems like it's following this exact procedure.

Your WiFi capabilities were at 100% because of this line

Dell Wireless 370 Bluetooth

The Bluez application was searching for a wireless driver that just wasn't there which could have consumed more memory and processing. I believe you have fixed the problem; great job!

As you can see the USB file system for the USB device file system control has failed because it wasn't responding, The command is using (cmd)

There's Android and IOS applications that hides your videos and images called keepsafe (hid) with human computer interaction (hci) and rqt is a software framework of ROS which manages various windows on your screen.

[ 450.803644] usb 3-1.2: usbfs: USBDEVFS_CONTROL failed cmd hid2hci rqt 33 rq 9 len 4 ret -71

| improve this answer | |
0

I had what I think is a related problem. A newly installed Xubuntu 18.04 i386 system failed to boot after I'd been doing a bit of a clearout of bloatware. As my Dell Inspiron-530 has neither wifi nor bluetooth I uninstalled all that stuff. The m/c then hung during cold start consuming loads of cpu and getting hot under the collar. Booting into recovery mode showed that there was an error in systemd-journald (couldn't see what it was as the screen rolled on too quickly) and hung with a message every 22 secs that cpu#0 was stuck and quoted systemd-udevd377. Seeing all the stuff in this thread I managed to get a clean shutdown from a live DVD boot and got the desktop started via recovery mode. Looking at synaptic I discovered that I'd accidentally removed libbluetooth3-dbg although I had left libbluetooth3 when I did my clearout. If you try to take out libbluetooth3 it takes out the network manager but there is no such warning for libbluetooth3-dbg. Re-einstalling libbluetooth3-dbg solved the problem.

I offer this in the hope that it sheds some light on others who might be experiencing a similar problem.

jg

| improve this answer | |

Not the answer you're looking for? Browse other questions tagged or ask your own question.