我的 Ubuntu 16.04 机器有 4 个 CPU 核心,其中一个(其中一个完全不同)总是有 90% 到 100% 的负载。
无论我在做什么,甚至当我什么都不做,没有开窗的时候,这都是真的。它发生在启动后或工作数小时后。
我在这里和这里阅读了两个流行的相关问题,但不幸的是,这些都没有帮助。
在我工作的大部分时间里,我的工作效率并没有受到这个问题的影响。我当时知道这个问题的唯一原因是风扇总是以最大功率工作,而 Ubuntu 的系统监控显示其中一个内核负载很重。
但作为额外的表现,我可能有 10% 的工作时间受到非常糟糕的响应能力的影响。
尤其是 UI(在动画期间和对点击做出反应时)非常慢。这让我想到,也许 CPU 也在做 GPU 的工作。但这可能只是一个没有根据的信念,下面的数据似乎也相互矛盾。
我担心这个问题,如果我不能解决它,是否会对我的计算机的生命周期产生(重大)影响。我不知道在数月或数年内持续负载 >90% 对 CPU 的影响。
无论如何,这是我可以从我的机器上收集的数据,这些数据可能相关或有帮助:
top
:
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
415 root 20 0 0 0 0 R 97,3 0,0 1:39.30 kworker/2:2
2442 john 20 0 663828 38704 29852 S 3,3 0,5 0:00.90 gnome-terminal-
1194 root 20 0 335728 69900 48392 S 2,3 0,9 0:08.36 Xorg
1821 john 20 0 1423440 114660 77600 S 1,3 1,5 0:03.77 compiz
6 root 20 0 0 0 0 D 0,3 0,0 0:00.84 kworker/u8:0
grep . -r /sys/firmware/acpi/interrupts/
:
/sys/firmware/acpi/interrupts/sci: 36
/sys/firmware/acpi/interrupts/error: 0
/sys/firmware/acpi/interrupts/gpe00: 0 invalid
/sys/firmware/acpi/interrupts/gpe01: 0 invalid
/sys/firmware/acpi/interrupts/gpe02: 0 invalid
/sys/firmware/acpi/interrupts/gpe03: 36 enabled
/sys/firmware/acpi/interrupts/gpe04: 0 invalid
(...)
/sys/firmware/acpi/interrupts/gpe1F: 0 disabled
/sys/firmware/acpi/interrupts/sci_not: 0
/sys/firmware/acpi/interrupts/ff_pmtimer: 0 invalid
/sys/firmware/acpi/interrupts/ff_rt_clk: 0 disabled
/sys/firmware/acpi/interrupts/gpe_all: 36
/sys/firmware/acpi/interrupts/ff_gbl_lock: 0 enabled
/sys/firmware/acpi/interrupts/ff_pwr_btn: 0 enabled
/sys/firmware/acpi/interrupts/ff_slp_btn: 0 invalid
uname -a
:
Linux my-host-name 4.4.0-47-generic #68-Ubuntu SMP Wed Oct 26 19:39:52 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
cat /proc/cmdline
:
BOOT_IMAGE=/vmlinuz-4.8.0-28-generic.efi.signed root=/dev/mapper/ubuntu--vg-root ro quiet splash vt.handoff=7
lspci -v
:
00:00.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Device 1576
Subsystem: Hewlett-Packard Company Device 81f9
Flags: bus master, fast devsel, latency 0
00:00.2 IOMMU: Advanced Micro Devices, Inc. [AMD] Device 1577
Subsystem: Hewlett-Packard Company Device 81f9
Flags: bus master, fast devsel, latency 0, IRQ 24
Capabilities: <access denied>
00:01.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Carrizo (rev ca) (prog-if 00 [VGA controller])
DeviceName: ATI EG BROADWAY
Subsystem: Hewlett-Packard Company Carrizo
Flags: bus master, fast devsel, latency 0, IRQ 227
Memory at e0000000 (64-bit, prefetchable) [size=256M]
Memory at f0800000 (64-bit, prefetchable) [size=8M]
I/O ports at 4000 [size=256]
Memory at f0500000 (32-bit, non-prefetchable) [size=256K]
Expansion ROM at f0580000 [disabled] [size=128K]
Capabilities: <access denied>
Kernel driver in use: amdgpu
Kernel modules: amdgpu
...
00:08.0 Encryption controller: Advanced Micro Devices, Inc. [AMD] Device 1578
Subsystem: Hewlett-Packard Company Device 81f9
Flags: bus master, fast devsel, latency 0, IRQ 255
Memory at f0540000 (64-bit, prefetchable) [size=128K]
Memory at f0300000 (32-bit, non-prefetchable) [size=1M]
Memory at f0570000 (32-bit, non-prefetchable) [size=4K]
Memory at f056a000 (32-bit, non-prefetchable) [size=8K]
Capabilities: <access denied>
...
01:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8101/2/6E PCI Express Fast/Gigabit Ethernet controller (rev 07)
Subsystem: Hewlett-Packard Company RTL8101/2/6E PCI Express Fast/Gigabit Ethernet controller
Flags: bus master, fast devsel, latency 0, IRQ 225
I/O ports at 3000 [size=256]
Memory at f0400000 (64-bit, non-prefetchable) [size=4K]
Memory at f0100000 (64-bit, prefetchable) [size=16K]
Capabilities: <access denied>
Kernel driver in use: r8169
Kernel modules: r8169
02:00.0 Network controller: Realtek Semiconductor Co., Ltd. RTL8723BE PCIe Wireless Network Adapter
DeviceName: Sanji2
Subsystem: Hewlett-Packard Company RTL8723BE PCIe Wireless Network Adapter
Flags: bus master, fast devsel, latency 0, IRQ 231
I/O ports at 2000 [size=256]
Memory at f1000000 (64-bit, non-prefetchable) [size=16K]
Capabilities: <access denied>
Kernel driver in use: rtl8723be
Kernel modules: rtl8723be
有人可以帮忙吗?
我已经能够找到这个问题的确切原因,尽管这并不是真正解决问题的方法:
进行全新的重新安装,逐个更改设置并逐个安装软件包,结果证明我可以通过设置“内置显示”来始终重现(甚至“切换”)问题在系统设置中设置为“关闭”。
我有一个通过 HDMI 连接的外接显示器,为了省电,我想完全关闭内置显示器(这可以工作,但会导致 CPU 负载高和 UI 变慢),而不是仅仅镜像它(没有任何缺点)。
除了 CPU 负载过高的问题外,当“内置显示器”关闭时,计算机(笔记本电脑)还会持续发出尖锐但安静的哔哔声。