笔记本电脑几分钟后随机关机/挂起。20.04.2 LTS

笔记本电脑几分钟后随机关机/挂起。20.04.2 LTS

我打开笔记本电脑,登录,然后 1-2 分钟后笔记本电脑关机。就在它完全关闭之前,它进入锁定屏幕。

这是今天开始的 - 而且我认为过去几天我没有安装任何更新。

编辑2

根据 waltinator 的建议,我检查了journalctl输出,发现有东西触发了电源开关。经过一番挖掘,我发现了这个问题 -https://superuser.com/questions/1071800/explanation-of-systemd-logind-in-auth-log

输出udevadm trigger如下。所以我现在的问题是 - 为什么网络摄像头、麦克风、HDMI 输出等与电源开关通信;这是否会导致随机断电;如果是,我该如何禁用这些消息?

$ udevadm trigger -v -n -g power-switch
/sys/devices/LNXSYSTM:00/LNXPWRBN:00/input/input3/event3
/sys/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0A08:00/LNXVIDEO:00/input/input21/event9
/sys/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0C0C:00/input/input0/event0
/sys/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0C0D:00/input/input2/event2
/sys/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0C0E:00/input/input1/event1
/sys/devices/pci0000:00/0000:00:14.0/usb1/1-8/1-8:1.0/input/input30/event18
/sys/devices/pci0000:00/0000:00:1f.3/sound/card0/input22/event10
/sys/devices/pci0000:00/0000:00:1f.3/sound/card0/input23/event11
/sys/devices/pci0000:00/0000:00:1f.3/sound/card0/input24/event12
/sys/devices/pci0000:00/0000:00:1f.3/sound/card0/input25/event13
/sys/devices/pci0000:00/0000:00:1f.3/sound/card0/input26/event14
/sys/devices/pci0000:00/0000:00:1f.3/sound/card0/input27/event15
/sys/devices/pci0000:00/0000:00:1f.3/sound/card0/input28/event16
/sys/devices/pci0000:00/0000:00:1f.3/sound/card0/input29/event17
/sys/devices/platform/INT33D5:00/input/input17/event8
/sys/devices/platform/i8042/serio0/input/input4/event4

$ udevadm trigger -v -n -g power-switch | xargs -i cat {}/../name
Power Button
Video Bus
Power Button
Lid Switch
Sleep Button
BisonCam,NB Pro: BisonCam,NB Pr
HDA Intel PCH Rear Mic
HDA Intel PCH Front Mic
HDA Intel PCH Headphone
HDA Intel PCH HDMI/DP,pcm=3
HDA Intel PCH HDMI/DP,pcm=7
HDA Intel PCH HDMI/DP,pcm=8
HDA Intel PCH HDMI/DP,pcm=9
HDA Intel PCH HDMI/DP,pcm=10
Intel HID events
AT Translated Set 2 keyboard

kern.log这是最近 5 次关机的输出。

May 26 17:23:52 jamest-Hybris kernel: [   17.087827] mce: CPU2: Package temperature/speed normal
May 26 17:23:52 jamest-Hybris kernel: [   17.087828] mce: CPU6: Package temperature/speed normal
May 26 17:23:52 jamest-Hybris kernel: [   17.193695] rfkill: input handler disabled
May 26 17:25:21 jamest-Hybris kernel: [  106.238840] wlp2s0: deauthenticating from 44:e9:dd:0c:a0:07 by local choice (Reason: 3=DEAUTH_LEAVING)
May 26 17:25:23 jamest-Hybris kernel: [  108.184069] PM: suspend entry (deep)
...
May 26 17:29:01 jamest-Hybris kernel: [   16.522151] rfkill: input handler enabled
May 26 17:29:03 jamest-Hybris kernel: [   18.299032] FAT-fs (sdb1): Volume was not properly unmounted. Some data may be corrupt. Please run fsck.
May 26 17:29:03 jamest-Hybris kernel: [   18.385620] rfkill: input handler disabled
May 26 17:30:28 jamest-Hybris kernel: [  103.505036] wlp2s0: deauthenticating from 44:e9:dd:0c:a0:07 by local choice (Reason: 3=DEAUTH_LEAVING)
May 26 17:30:30 jamest-Hybris kernel: [  105.493465] PM: suspend entry (deep)
...
May 26 17:32:32 jamest-Hybris kernel: [   41.950990] mce: CPU7: Package temperature/speed normal
May 26 17:32:32 jamest-Hybris kernel: [   41.950990] mce: CPU4: Package temperature/speed normal
May 26 17:32:32 jamest-Hybris kernel: [   41.950991] mce: CPU0: Package temperature/speed normal
May 26 17:33:35 jamest-Hybris kernel: [  104.349444] wlp2s0: deauthenticating from 44:e9:dd:0c:a0:07 by local choice (Reason: 3=DEAUTH_LEAVING)
May 26 17:33:39 jamest-Hybris kernel: [  109.180738] PM: suspend entry (deep)
...
May 26 17:35:47 jamest-Hybris kernel: [   15.053073] rfkill: input handler enabled
May 26 17:35:48 jamest-Hybris kernel: [   15.404181] IPv6: ADDRCONF(NETDEV_CHANGE): wlp2s0: link becomes ready
May 26 17:35:49 jamest-Hybris kernel: [   16.834008] rfkill: input handler disabled
May 26 17:37:16 jamest-Hybris kernel: [  103.671054] wlp2s0: deauthenticating from 44:e9:dd:0c:a0:07 by local choice (Reason: 3=DEAUTH_LEAVING)
May 26 17:37:20 jamest-Hybris kernel: [  108.026954] PM: suspend entry (deep)

我没有(故意)做任何会触发暂停的事情。

一些系统信息

sudo lshw -C 视频

  *-display                 
       description: VGA compatible controller
       product: UHD Graphics 630 (Mobile)
       vendor: Intel Corporation
       physical id: 2
       bus info: pci@0000:00:02.0
       version: 00
       width: 64 bits
       clock: 33MHz
       capabilities: pciexpress msi pm vga_controller bus_master cap_list rom
       configuration: driver=i915 latency=0
       resources: irq:137 memory:a0000000-a0ffffff memory:90000000-9fffffff ioport:4000(size=64) memory:c0000-dffff

串行通信

00:00.0 Host bridge: Intel Corporation 8th Gen Core 4-core Processor Host Bridge/DRAM Registers [Coffee Lake H] (rev 07)
00:02.0 VGA compatible controller: Intel Corporation UHD Graphics 630 (Mobile)
00:04.0 Signal processing controller: Intel Corporation Xeon E3-1200 v5/E3-1500 v5/6th Gen Core Processor Thermal Subsystem (rev 07)
00:12.0 Signal processing controller: Intel Corporation Cannon Lake PCH Thermal Controller (rev 10)
00:14.0 USB controller: Intel Corporation Cannon Lake PCH USB 3.1 xHCI Host Controller (rev 10)
00:14.2 RAM memory: Intel Corporation Cannon Lake PCH Shared SRAM (rev 10)
00:15.0 Serial bus controller [0c80]: Intel Corporation Cannon Lake PCH Serial IO I2C Controller #0 (rev 10)
00:15.1 Serial bus controller [0c80]: Intel Corporation Cannon Lake PCH Serial IO I2C Controller #1 (rev 10)
00:16.0 Communication controller: Intel Corporation Cannon Lake PCH HECI Controller (rev 10)
00:17.0 SATA controller: Intel Corporation Cannon Lake Mobile PCH SATA AHCI Controller (rev 10)
00:1d.0 PCI bridge: Intel Corporation Cannon Lake PCH PCI Express Root Port #9 (rev f0)
00:1d.5 PCI bridge: Intel Corporation Cannon Lake PCH PCI Express Root Port #14 (rev f0)
00:1d.6 PCI bridge: Intel Corporation Cannon Lake PCH PCI Express Root Port #15 (rev f0)
00:1f.0 ISA bridge: Intel Corporation HM470 Chipset LPC/eSPI Controller (rev 10)
00:1f.3 Audio device: Intel Corporation Cannon Lake PCH cAVS (rev 10)
00:1f.4 SMBus: Intel Corporation Cannon Lake PCH SMBus Controller (rev 10)
00:1f.5 Serial bus controller [0c80]: Intel Corporation Cannon Lake PCH SPI Controller (rev 10)
02:00.0 Network controller: Intel Corporation Wireless-AC 9260 (rev 29)
03:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTL8411B PCI Express Card Reader (rev 01)
03:00.1 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 12)

编辑

按照 waltinator 的回复,这里是 journalctl 的相关部分。看起来系统认为电源按钮被按下了,然后在 4-5 秒后关闭。我肯定没有按下按钮,所以看起来可能是硬件问题。

May 26 17:37:15 machine-abc systemd-logind[968]: Power key pressed.
May 26 17:37:15 machine-abc gnome-shell[1876]: Window manager warning: Overwriting existing binding of keysym 38 with keysym 38 (keycode 11).
...
...
...
May 26 17:37:20 machine-abc systemd[1]: Reached target Sleep.
May 26 17:37:20 machine-abc systemd[1]: Starting Suspend...
May 26 17:37:20 machine-abc systemd-sleep[3054]: Suspending system...
May 26 17:37:20 machine-abc kernel: PM: suspend entry (deep)

答案1

在“突然关机”(又称“系统崩溃”)并重新启动后,终端命令sudo journalctl -b -1 -e将显示上一次启动日志的结尾。如果那里没有任何提示,则怀疑电源/过热。

阅读man journalctl以了解如何从日志中提取信息。

journalctl您可以在 了解我如何更轻松地利用https://askubuntu.com/users/25618/waltinator

相关内容