与 redhat bugzilla 中发布的相同 - kcompcd0 using 100% cpu已关闭INSUFFICIENT_DATA
。
也一样
重新打开,因为那里的解决方案对我不起作用。
这是我的情况:
- Ubuntu 21.10主机和 Windows 10 Enterprise 客户端,带有 VMware Workstation 16 v 16.2.0 build-18760230
- 我没有做任何花哨或重负载的事情,就在正常使用 Windows 10 一天(轻负载)之后,事情开始变得疯狂。
- 该过程
kcompactd0
不断在一个内核上vmware-vmx
使用 100% cpu,在八个内核上使用 100% cpu。 - 当它发生时,它通常会持续几分钟。然后在一两分钟后再次启动。
- “kcompactd0 仅与 drop_caches 一起消失。当它达到 100% 时,vmware 虚拟机来宾完全没有响应(windows 10 ltsc vm)”所以我只尝试了 drop_caches 一次,并确认了该行为。
根据上游的要求,这里有更多信息:
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 21.10
Release: 21.10
Codename: impish
$ grep -r . /sys/kernel/mm/transparent_hugepage/*
/sys/kernel/mm/transparent_hugepage/defrag:always defer defer+madvise [madvise] never
/sys/kernel/mm/transparent_hugepage/enabled:always [madvise] never
/sys/kernel/mm/transparent_hugepage/hpage_pmd_size:2097152
/sys/kernel/mm/transparent_hugepage/khugepaged/defrag:1
/sys/kernel/mm/transparent_hugepage/khugepaged/max_ptes_shared:256
/sys/kernel/mm/transparent_hugepage/khugepaged/scan_sleep_millisecs:10000
/sys/kernel/mm/transparent_hugepage/khugepaged/max_ptes_none:511
/sys/kernel/mm/transparent_hugepage/khugepaged/pages_to_scan:4096
/sys/kernel/mm/transparent_hugepage/khugepaged/max_ptes_swap:64
/sys/kernel/mm/transparent_hugepage/khugepaged/alloc_sleep_millisecs:60000
/sys/kernel/mm/transparent_hugepage/khugepaged/pages_collapsed:0
/sys/kernel/mm/transparent_hugepage/khugepaged/full_scans:19
/sys/kernel/mm/transparent_hugepage/shmem_enabled:always within_size advise [never] deny force
/sys/kernel/mm/transparent_hugepage/use_zero_page:1
$ cat /proc/90/stack | wc
0 0 0
echo never > /sys/kernel/mm/transparent_hugepage/defrag
echo 0 > /sys/kernel/mm/transparent_hugepage/khugepaged/defrag
echo never > /sys/kernel/mm/transparent_hugepage/enabled
$ grep -r . /sys/kernel/mm/transparent_hugepage/*
/sys/kernel/mm/transparent_hugepage/defrag:always defer defer+madvise madvise [never]
/sys/kernel/mm/transparent_hugepage/enabled:always madvise [never]
/sys/kernel/mm/transparent_hugepage/hpage_pmd_size:2097152
/sys/kernel/mm/transparent_hugepage/khugepaged/defrag:0
/sys/kernel/mm/transparent_hugepage/khugepaged/max_ptes_shared:256
/sys/kernel/mm/transparent_hugepage/khugepaged/scan_sleep_millisecs:10000
/sys/kernel/mm/transparent_hugepage/khugepaged/max_ptes_none:511
/sys/kernel/mm/transparent_hugepage/khugepaged/pages_to_scan:4096
/sys/kernel/mm/transparent_hugepage/khugepaged/max_ptes_swap:64
/sys/kernel/mm/transparent_hugepage/khugepaged/alloc_sleep_millisecs:60000
/sys/kernel/mm/transparent_hugepage/khugepaged/pages_collapsed:0
/sys/kernel/mm/transparent_hugepage/khugepaged/full_scans:19
/sys/kernel/mm/transparent_hugepage/shmem_enabled:always within_size advise [never] deny force
/sys/kernel/mm/transparent_hugepage/use_zero_page:1
基本上,解决方法的来源是Fedora 错误报告“khugepaged eating 100%CPU”。该错误从未被修复,“解决方案”是针对 2013 年的 Fedora 17 的,并且
对于最后 3 个,也许是 4-5 个 Fedora 内核版本,我再也没有遇到过这个问题。
但现在又发生了。