11

After upgrde from 15.10 to 16.04, I noticed my netbook fan was constantly turning at full throtle. I checked the process mnitoor and noticed KswapD0 used 100% of one core.

What is the problem ? Because of this, my netbook is slow and i'm afraid of processor overheating.

dupont
  • 1,707
  • 6
  • 17
  • 24
  • That certainly does sound like a bug you should report, but even if all cores are running at 100%, it should not overheat. If it does, your hardware is defective. – psusi Apr 24 '16 at 17:25
  • 2
    This happened to me on a AWS instance with low memory as folks in the link provided above in regards to BUG #1518457, after I updated from a 14.04 LTS to 16.04 LTS with a do -release-upgrade. Refer to the discussion thread for more detail. https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1518457 – prraw Aug 22 '16 at 20:41

1 Answers1

22

This seems to be something that commonly (but not exclusively) pops up w/ low memory systems. You can check out the bug that's tracking this issue: Bug #1518457: kswapd0 100% CPU usage

There isn't an actual fix yet, but there are a couple workarounds that may fix the problem for you:

  1. Add echo 1 > /proc/sys/vm/drop_caches to a regular crontab and/or run that command manually when kswapd acts up
  2. Comment out line 2 in /lib/udev/rules.d/40-vm-hotadd.rules (see the bug link for more discussion)
lhl
  • 221
  • 1
  • 2
  • *1.* Drops clean page caches. It is non-destructive, but can cause performance problems. – Zaz Sep 01 '16 at 10:19
  • 5
    *2.* You should quote the line to be removed in case they change the order of the lines in the future. – Zaz Sep 01 '16 at 10:20
  • 3
    true, it's actually line 3 now (considering the first line is a comment) `ATTR{[dmi/id]sys_vendor}=="Xen", GOTO="vm_hotadd_apply"` – Gubatron Sep 26 '16 at 22:25
  • do I need to sudo first? and how do I sudo for the cronjob – Maysam Torabi Oct 20 '16 at 03:59
  • 1
    The fix has been released for 16.04 and has been confirmed fixed by multiple people. Run apt-get upgrade and restart. – Ryan Lavelle Oct 25 '16 at 22:56
  • [This problem "never solved"](https://ubuntuforums.org/showthread.php?t=2072042), is it? So, today, 2017, there are a workwaround to avoid crashing UBUNTU with kswapd0 consuming all my CPY time? – Peter Krauss Nov 06 '17 at 18:46
  • See another solution at https://askubuntu.com/a/530661/439867 – Peter Krauss Nov 06 '17 at 19:00