kworker using lots of cpu with new LTS kernel 5.4.17-1

I've been running the LTS kernel 4.19.101-1-MANJARO x86_64 for some time with no issues. It seems there is a new LTS kernel 5.4.17-1 so I thought I should switch. Everything seems to work, but after a while kworker starts going crazy, running at 12% CPU continuously. With htop I see CPU #5 is running at 100% all the time. Hardware is Intel NUC with i5-8259u, 16 GB RAM. DE is XFCE.
I can go back to 4.19.101-1 but won't I need to start using the new LTS kernel sooner or later? Any recommendations?
Thanks!

Linux 4.19 is supported until December of this year. Hopefully, that gives enough time for many issues with version 5.4 to be fixed.

kworker processes are kernel worker processes and there are a few of those.

What's the output to:

ps aux | sort --numeric-sort --reverse --key=3,3 | head --lines=5

:question:

Thanks for the reply. Currently waiting for the issue to pop up again. Will post when it does. Cheers.

kworker --> interrupt kernel from a component that do not have a driver ...
have you added something or changed something in Bios ?

1 Like

Well, system has been up for 36 hrs and the bad behavior has not recurred. I hadn't made any change to hardware of BIOS. I wasn't doing anything else abnormal, so it's difficult to diagnose. I see there is an update to the kernel so it is now 5.4.18-1. I will do the update and report back if I see any issues.

1 Like


JJMCC

3m

Not so fast - it's baaack! Even with kernel 5.4.18-1, I see 12% continuous cpu usage (= 1 out of 8 cpus going 100%). Here is the output from

ps aux | sort --numeric-sort --reverse --key=3,3 | head --lines=5

root 2172 10.6 0.0 0 0 ? R 16:23 25:15 [kworker/u16:43+netns]
family 11902 9.8 1.2 899700 204436 ? Sl 20:16 0:17 /opt/vivaldi/vivaldi-bin --type=renderer --disable-webrtc-apm-in-audio-service --field-trial-handle=12889051747699806284,6602437540969146922,131072 --lang=en-US --disable-oor-cors --enable-auto-reload --num-raster-threads=4 --enable-main-frame-before-activation --service-request-channel-token=8391264159275629279 --renderer-client-id=9 --no-v8-untrusted-code-mitigations --running-vivaldi --shared-files=v8_context_snapshot_data:100,v8_natives_data:101
family 11863 5.0 0.6 373840 109264 ? Sl 20:16 0:08 /opt/vivaldi/vivaldi-bin --type=gpu-process --field-trial-handle=12889051747699806284,6602437540969146922,131072 --gpu-preferences=KAAAAAAAAAAgAAAgAAAAAAAAYAAAAAAAEAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAA --service-request-channel-token=9110743595037689109
family 11901 3.3 1.0 665508 167492 ? Sl 20:16 0:05 /opt/vivaldi/vivaldi-bin --type=renderer --disable-webrtc-apm-in-audio-service --field-trial-handle=12889051747699806284,6602437540969146922,131072 --lang=en-US --extension-process --disable-oor-cors --enable-auto-reload --num-raster-threads=4 --enable-main-frame-before-activation --service-request-channel-token=5889979058336653870 --renderer-client-id=7 --no-v8-untrusted-code-mitigations --running-vivaldi --shared-files=v8_context_snapshot_data:100,v8_natives_data:101
family 11832 3.2 1.2 622360 205052 ? SLl 20:16 0:05 /opt/vivaldi/vivaldi-bin -no-remote

Please let me know if I can do any more diagnostics.

  • What changed before it came back?
  • Did you run a particular application?
  • Does this also happen when you use Firefox instead of Vivaldi?
  • Could you post the same output with --lines=10 because I was too stringent in my first request...

(I feel like the proverbial madman asking more questions than 7 wise men can answer now)

:grin: :wink:

Difficult to say what changed or if a particular app caused it. The system was up for 36 hrs, I went about my business, running a couple of wine programs, doing backup with duplicity, putting it to sleep, waking up, etc, etc. I have conky running, and noticed after a while the cpus were busy again and kworker was the culprit. Couldn't say exactly when it happened. I can certainly try to be more observant, but it will take time. The problem goes away with reboot but seems to take a day or more before it shows up. I will try to pin it down. Meanwhile, here's the output with --lines=10:

root      2172 15.6  0.0      0     0 ?        R    Feb11 266:22 [kworker/u16:43+netns]
family   21587  0.8  1.3 881872 222044 ?       Sl   18:38   1:03 /opt/vivaldi/vivaldi-bin --type=renderer --disable-webrtc-apm-in-audio-service --field-trial-handle=11130534697009733406,2502016190942320003,131072 --lang=en-US --disable-oor-cors --enable-auto-reload --num-raster-threads=4 --enable-main-frame-before-activation --service-request-channel-token=15791048592880812669 --renderer-client-id=9 --no-v8-untrusted-code-mitigations --running-vivaldi --shared-files=v8_context_snapshot_data:100,v8_natives_data:101
family    1154  0.6  0.0 1469936 8204 ?        Sl   Feb11  14:04 /usr/bin/conky
root       721  0.5  0.3 680288 54748 tty7     Ssl+ Feb11  11:39 /usr/lib/Xorg :0 -seat seat0 -auth /run/lightdm/root/:0 -nolisten tcp vt7 -novtswitch
family   21552  0.3  0.6 379516 109728 ?       Sl   18:38   0:28 /opt/vivaldi/vivaldi-bin --type=gpu-process --field-trial-handle=11130534697009733406,2502016190942320003,131072 --gpu-preferences=KAAAAAAAAAAgAAAgAAAAAAAAYAAAAAAAEAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAA --service-request-channel-token=7960155907157675665
family   21519  0.2  1.3 735536 219804 ?       SLl  18:38   0:21 /opt/vivaldi/vivaldi-bin -no-remote
family    1078  0.1  0.3 729088 52892 ?        Sl   Feb11   3:41 xfwm4
USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
systemd+   604  0.0  0.0  89840  5972 ?        Ssl  Feb11   0:00 /usr/lib/systemd/systemd-timesyncd
rtkit     1102  0.0  0.0 152680  2700 ?        SNsl Feb11   0:00 /usr/lib/rtkit-daemon

I've found a bug concerning kworker netns: try disabling ipv6 and report back.

This is definitely the same symptoms I had, but a totally different cause as kworker is just the symptom of the disease just like high fever is not a disease but pneumonia is...

:mask: :wink:

OK ipv6 is now disabled via ipv6.disable=1 in grub. Waiting for something to happen... Could be a while. Will report back after a couple of days, or less if it happens sooner.

Happened sooner than I thought. So disabling ipv6 did not help. Here, once again is the output from

ps aux | grep kworker | sort --numeric-sort --reverse --key=3,3 | head --lines=10

root       183 78.0  0.0      0     0 ?        R    20:28  36:05 [kworker/u16:2+netns]
root      3417  0.1  0.0      0     0 ?        I    20:58   0:01 [kworker/u16:4-events_power_efficient]
root     17243  0.1  0.0      0     0 ?        I    21:09   0:00 [kworker/u16:5-events_unbound]
root      8506  0.0  0.0      0     0 ?        I    21:02   0:00 [kworker/1:2-events]
root        79  0.0  0.0      0     0 ?        I    20:28   0:01 [kworker/u16:1-events_power_efficient]
root       738  0.0  0.0      0     0 ?        I<   20:28   0:00 [kworker/0:1H-events_highpri]
root       710  0.0  0.0      0     0 ?        I    20:28   0:00 [kworker/5:2-events]
root       694  0.0  0.0      0     0 ?        I<   20:28   0:00 [kworker/u17:1-rb_allocator]
root        65  0.0  0.0      0     0 ?        I<   20:28   0:00 [kworker/7:0H-kblockd]
root       640  0.0  0.0      0     0 ?        I<   20:28   0:00 [kworker/1:1H-events_highpri]

Yeah, and now nothing is running so not application-driven...

I'm all out of bright ideas and can only advise you to go back to 4.19 by now or try the latest 5.5...

pamac install cpulimit
cpulimit --pid=183 --limit=50    

might be able to help in the above use-case...

:sob:

Forum kindly sponsored by