kworker blocked for more than 120 seconds Ubuntu 17.10

I decided to upgrade to 17.10 on my Thinkpad.

Now every time I try to shut it down via console or menu) or reboot it, it takes ages.

TTY gives me several errors connected to hung_task_timeout_secs, reaching from kworker, over networkmanager down to wpa_supplicant.

I tried reinstalling with different ISOs (daily-build from 2 days ago, beta2, and the rc one from today) and still get the same error every time.

Any ideas what could cause that issue? Right now I'm running 17.10 on two other, different PCs without any problems whatsoever.

EDIT: deborphan doesn't return any orphaned packages. I think I might have found something though. I decided to completely wipe the disc, including my dualboot windows. Reinstalled, and everything worked fine. Today in university the problem reappeared.

Now the interesting part is: I think it is related to my wifi. At home, during installation and after, I had it plugged in via cable, and had no problems at all. But with only wifi in university it reappeared. So I gave it a try and plugged in the cable again at home, and it works again. Removed cable, restarted, and the problem reappears. Wifi-Card is a Qualcomm Atheros.


Solution 1:

Seems like a kernel issue related to wireless drivers and supplicant. I upgraded to 17.10 yesterday, and had the exact same problem. Removing orphan packages did not help.

After looking at dmesg output I realized it had something to do with the kernel (4.13.0-16-generic) and decided to use an earlier stable version (4.10.0-37-generic). Now everything works fine. Hope this helps.

Note: Below is the dmesg output:

wpa_supplicant[1488]: wlp1s0: CTRL-EVENT-SCAN-FAILED ret=-16 retry=1
 kernel: [  363.484267] INFO: task kworker/u8:1:51 blocked for more than 120 seconds.
 kernel: [  363.484281]       Tainted: G           OE   4.13.0-16-generic #19-Ubuntu
 kernel: [  363.484285] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
 kernel: [  363.484290] kworker/u8:1    D    0    51      2 0x00000000
 kernel: [  363.484359] Workqueue: phy0 ieee80211_ba_session_work [mac80211]
 kernel: [  363.484363] Call Trace:
 kernel: [  363.484380]  __schedule+0x28b/0x890
 kernel: [  363.484388]  schedule+0x36/0x80
 kernel: [  363.484396]  schedule_preempt_disabled+0xe/0x10
 kernel: [  363.484404]  __mutex_lock.isra.2+0x190/0x4e0
 kernel: [  363.484414]  __mutex_lock_slowpath+0x13/0x20
 kernel: [  363.484421]  ? __mutex_lock_slowpath+0x13/0x20
 kernel: [  363.484428]  mutex_lock+0x2f/0x40
 kernel: [  363.484472]  __ieee80211_start_rx_ba_session+0x1b7/0x5a0 [mac80211]
 kernel: [  363.484479]  ? dequeue_entity+0xed/0x4b0
 kernel: [  363.484516]  ieee80211_ba_session_work+0x164/0x250 [mac80211]
 kernel: [  363.484526]  process_one_work+0x1e7/0x410
 kernel: [  363.484532]  worker_thread+0x4a/0x410
 kernel: [  363.484537]  kthread+0x125/0x140
 kernel: [  363.484543]  ? process_one_work+0x410/0x410
 kernel: [  363.484548]  ? kthread_create_on_node+0x70/0x70
 kernel: [  363.484554]  ret_from_fork+0x25/0x30

Solution 2:

It may well be this bug on Launchpad. A fix is promised in the "next Artful kernel release".