使固定

使固定

我认为我的问题与已经提出的问题非常相似:

  1. 从 18.04 升级后,20.04 暂停时崩溃
  2. https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1882917- 我也厌倦了该用户尝试做的所有事情。
  3. https://github.com/pop-os/pop/issues/1172- 在 POP OS 上也发生了非常类似的事情。

我认为这是有更深层次的原因,与内核有关。我使用的是 AMD Ryzen 7,此行为在以下设备上重现:

  • Ubuntu 20.04
  • Ubuntu 21.04
  • 流行操作系统 20.04
  • Fedora 34

一个可以毫无问题地运行的发行版:

  • 深度 20

我连续三天不眠不休地尝试设置我的新机器,从一个发行版跳到另一个发行版,试图找到解决方案。

以下是一些有用的命令输出:

$ sudo lshw -C memory
  *-memory                  
       description: System Memory
       physical id: 1
       slot: System board or motherboard
       size: 24GiB
     *-bank:0
          description: SODIMM DDR4 Synchronous Unbuffered (Unregistered) 3200 MHz (0.3 ns)
          product: 4ATF1G64HZ-3G2E1
          vendor: Micron Technology
          physical id: 0
          serial: 00000000
          slot: DIMM 0
          size: 8GiB
          width: 64 bits
          clock: 3200MHz (0.3ns)
     *-bank:1
          description: SODIMM DDR4 Synchronous Unbuffered (Unregistered) 3200 MHz (0.3 ns)
          product: M471A2K43EB1-CWE
          vendor: Samsung
          physical id: 1
          serial: 419EE09E
          slot: DIMM 0
          size: 16GiB
          width: 64 bits
          clock: 3200MHz (0.3ns)
  *-cache:0
       description: L1 cache
       physical id: 3
       slot: L1 - Cache
       size: 512KiB
       capacity: 512KiB
       clock: 1GHz (1.0ns)
       capabilities: pipeline-burst internal write-back unified
       configuration: level=1
  *-cache:1
       description: L2 cache
       physical id: 4
       slot: L2 - Cache
       size: 4MiB
       capacity: 4MiB
       clock: 1GHz (1.0ns)
       capabilities: pipeline-burst internal write-back unified
       configuration: level=2
  *-cache:2
       description: L3 cache
       physical id: 5
       slot: L3 - Cache
       size: 8MiB
       capacity: 8MiB
       clock: 1GHz (1.0ns)
       capabilities: pipeline-burst internal write-back unified
       configuration: level=3
  *-firmware
       description: BIOS
       vendor: LENOVO
       physical id: e
       version: R1BET63W(1.32 )
       date: 04/12/2021
       size: 128KiB
       capacity: 32MiB
       capabilities: pci pnp upgrade shadowing cdboot bootselect edd int13floppy720 int5printscreen int9keyboard int14serial int17printer int10video acpi usb biosbootspecification uefi
$ uname -a
Linux thinkpad 5.11.0-7614-generic #15~1622578982~20.04~383c0a9~dev-Ubuntu SMP Wed Jun 2 00:50:47 U x86_64 x86_64 x86_64 GNU/Linux
$ lspci
00:00.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Root Complex
00:00.2 IOMMU: Advanced Micro Devices, Inc. [AMD] Renoir IOMMU
00:01.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe Dummy Host Bridge
00:02.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe Dummy Host Bridge
00:02.1 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe GPP Bridge
00:02.2 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe GPP Bridge
00:02.3 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe GPP Bridge
00:02.4 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe GPP Bridge
00:02.5 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe GPP Bridge
00:02.6 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe GPP Bridge
00:02.7 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe GPP Bridge
00:08.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe Dummy Host Bridge
00:08.1 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir Internal PCIe GPP Bridge to Bus
00:14.0 SMBus: Advanced Micro Devices, Inc. [AMD] FCH SMBus Controller (rev 51)
00:14.3 ISA bridge: Advanced Micro Devices, Inc. [AMD] FCH LPC Bridge (rev 51)
00:18.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 0
00:18.1 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 1
00:18.2 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 2
00:18.3 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 3
00:18.4 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 4
00:18.5 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 5
00:18.6 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 6
00:18.7 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 7
01:00.0 Non-Volatile memory controller: Sandisk Corp Device 5006
02:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 0e)
02:00.1 Serial controller: Realtek Semiconductor Co., Ltd. Device 816a (rev 0e)
02:00.2 Serial controller: Realtek Semiconductor Co., Ltd. Device 816b (rev 0e)
02:00.3 IPMI Interface: Realtek Semiconductor Co., Ltd. Device 816c (rev 0e)
02:00.4 USB controller: Realtek Semiconductor Co., Ltd. Device 816d (rev 0e)
03:00.0 Network controller: Intel Corporation Wi-Fi 6 AX200 (rev 1a)
04:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTS522A PCI Express Card Reader (rev 01)
05:00.0 Wireless controller [0d40]: Intel Corporation XMM7360 LTE Advanced Modem (rev 01)
06:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 15)
07:00.0 USB controller: Renesas Technology Corp. uPD720202 USB 3.0 Host Controller (rev 02)
08:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Renoir (rev d1)
08:00.1 Audio device: Advanced Micro Devices, Inc. [AMD/ATI] Device 1637
08:00.2 Encryption controller: Advanced Micro Devices, Inc. [AMD] Family 17h (Models 10h-1fh) Platform Security Processor
08:00.3 USB controller: Advanced Micro Devices, Inc. [AMD] Renoir USB 3.1
08:00.4 USB controller: Advanced Micro Devices, Inc. [AMD] Renoir USB 3.1
08:00.5 Multimedia controller: Advanced Micro Devices, Inc. [AMD] Raven/Raven2/FireFlight/Renoir Audio Processor (rev 01)
08:00.6 Audio device: Advanced Micro Devices, Inc. [AMD] Family 17h (Models 10h-1fh) HD Audio Controller

我也打开了全盘加密!

如果我可以提供任何其他信息来帮助解决这个问题,请告诉我。

答案1

使固定

我也遇到了这个问题*,在我执行以下操作后它已修复:

1. 编辑/etc/default/grub

  1. 使用 vim 打开:sudo vim /etc/default/grub

  2. 添加amd_iommu=off到选项GRUB_CMDLINE_LINUX_DEFAULT。(对我来说,这是GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"开始,然后GRUB_CMDLINE_LINUX_DEFAULT="quiet splash amd_iommu=off"是编辑之后。)

2. 更新 grub

跑步sudo update-grub


在此指南中找到了它:https://itectec.com/ubuntu/ubuntu-ubuntu-18-04-crashes-freezes-after-sleep-suspend/


*我的问题

我遇到的问题与修复之前完全相同(以防有人遇到类似但不相同的问题)。

重现步骤

与提问者相同,但您也可以通过简单地让屏幕进入睡眠状态(待机)而不是挂起计算机来触发它。

  1. 点击ctrl+alt+L锁定屏幕。等待屏幕变黑。
  2. 按任意键即可将其唤醒。

行为

当屏幕唤醒时,我可以看到锁定屏幕,但它被冻结了;密码字段中的插入符号没有像平常一样闪烁,鼠标或键盘的输入似乎没有任何作用。唯一的例外是重新订阅(按住alt+SysRq,,,,,,R)确实重新E启动了机器。ISUB

答案2

这个问题似乎与暂停有关。每当系统暂停时,它就会冻结,除了强制重启外,不会对任何操作做出响应。因此,暂时禁用暂停功能已解决了这个问题。

  • 禁用所有睡眠选项:

    sudo systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target
    
  • 阻止系统在盖子放下时进入睡眠状态:

    sudo vim /etc/systemd/logind.conf
    

    并添加/更新以下 3 行:

    [Login] 
    HandleLidSwitch=ignore 
    HandleLidSwitchDocked=ignore
    LidSwitchIgnoreInhibited=no
    

相关内容