唤醒后显示屏空白,使用外接显示器作为 HP 笔记本电脑的主显示器

唤醒后显示屏空白,使用外接显示器作为 HP 笔记本电脑的主显示器

我在跑

No LSB modules are available.
Distributor ID: Debian
Description:    Debian GNU/Linux 10 (buster)
Release:    10
Codename:   buster

使用 XFCE。我的电脑规格是:

00:00.0 Host bridge: Intel Corporation Skylake Host Bridge/DRAM Registers (rev 07)
00:02.0 VGA compatible controller: Intel Corporation HD Graphics 530 (rev 06)
00:14.0 USB controller: Intel Corporation Sunrise Point-H USB 3.0 xHCI Controller (rev 31)
00:14.2 Signal processing controller: Intel Corporation Sunrise Point-H Thermal subsystem (rev 31)
00:16.0 Communication controller: Intel Corporation Sunrise Point-H CSME HECI #1 (rev 31)
00:16.3 Serial controller: Intel Corporation Sunrise Point-H KT Redirection (rev 31)
00:17.0 SATA controller: Intel Corporation Sunrise Point-H SATA Controller [AHCI mode] (rev 31)
00:1c.0 PCI bridge: Intel Corporation Sunrise Point-H PCI Express Root Port #1 (rev f1)
00:1c.1 PCI bridge: Intel Corporation Sunrise Point-H PCI Express Root Port #2 (rev f1)
00:1c.4 PCI bridge: Intel Corporation Sunrise Point-H PCI Express Root Port #5 (rev f1)
00:1d.0 PCI bridge: Intel Corporation Sunrise Point-H PCI Express Root Port #9 (rev f1)
00:1f.0 ISA bridge: Intel Corporation Sunrise Point-H LPC Controller (rev 31)
00:1f.2 Memory controller: Intel Corporation Sunrise Point-H PMC (rev 31)
00:1f.3 Audio device: Intel Corporation Sunrise Point-H HD Audio (rev 31)
00:1f.4 SMBus: Intel Corporation Sunrise Point-H SMBus (rev 31)
00:1f.6 Ethernet controller: Intel Corporation Ethernet Connection (2) I219-LM (rev 31)
01:00.0 Network controller: Intel Corporation Wireless 8260 (rev 3a)
02:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTS522A PCI Express Card Reader (rev 01)
04:00.0 Non-Volatile memory controller: Samsung Electronics Co Ltd NVMe SSD Controller SM961/PM961

我还有以下端口,我使用 DP-1 连接我的外接显示器

Screen 0: minimum 320 x 200, current 2560 x 1440, maximum 8192 x 8192
eDP-1 connected (normal left inverted right x axis y axis)
   1920x1080     60.01 +  59.97    59.96    59.93    40.01  
   1680x1050     59.95    59.88  
   1600x1024     60.17  
   1400x1050     59.98  
   1600x900      59.99    59.94    59.95    59.82  
   1280x1024     60.02  
   1440x900      59.89  
   1400x900      59.96    59.88  
   1280x960      60.00  
   1440x810      60.00    59.97  
   1368x768      59.88    59.85  
   1360x768      59.80    59.96  
   1280x800      59.99    59.97    59.81    59.91  
   1152x864      60.00  
   1280x720      60.00    59.99    59.86    59.74  
   1024x768      60.04    60.00  
   960x720       60.00  
   928x696       60.05  
   896x672       60.01  
   1024x576      59.95    59.96    59.90    59.82  
   960x600       59.93    60.00  
   960x540       59.96    59.99    59.63    59.82  
   800x600       60.00    60.32    56.25  
   840x525       60.01    59.88  
   864x486       59.92    59.57  
   800x512       60.17  
   700x525       59.98  
   800x450       59.95    59.82  
   640x512       60.02  
   720x450       59.89  
   700x450       59.96    59.88  
   640x480       60.00    59.94  
   720x405       59.51    58.99  
   684x384       59.88    59.85  
   680x384       59.80    59.96  
   640x400       59.88    59.98  
   576x432       60.06  
   640x360       59.86    59.83    59.84    59.32  
   512x384       60.00  
   512x288       60.00    59.92  
   480x270       59.63    59.82  
   400x300       60.32    56.34  
   432x243       59.92    59.57  
   320x240       60.05  
   360x202       59.51    59.13  
   320x180       59.84    59.32  
DP-1 connected primary 2560x1440+0+0 (normal left inverted right x axis y axis) 708mm x 398mm
   2560x1440     59.95*+
   1920x1080     60.00    60.00    59.94  
   1680x1050     59.95  
   1600x900      60.00  
   1280x1024     75.02    60.02  
   1440x900      59.89  
   1280x800      59.81  
   1152x864      75.00  
   1280x720      60.00    59.94  
   1024x768      75.03    70.07    60.00  
   832x624       74.55  
   800x600       72.19    75.00    60.32    56.25  
   640x480       75.00    72.81    66.67    60.00    59.94  
   720x400       70.08  
HDMI-1 disconnected (normal left inverted right x axis y axis)
DP-2 disconnected (normal left inverted right x axis y axis)
HDMI-2 disconnected (normal left inverted right x axis y axis)
DP-3 disconnected (normal left inverted right x axis y axis)
HDMI-3 disconnected (normal left inverted right x axis y axis)

Dp-1 被设置为我的主显示器。每次我想让电脑挂起,休息一下然后回来,按下一个键来唤醒电脑时,我只会看到黑屏。这是我到目前为止得到的睡眠日志:

Sep 08 00:18:59 maroufi systemd-sleep[2784]: Suspending system...
Sep 08 12:52:13 maroufi systemd-sleep[2784]: System resumed.
Sep 08 13:10:12 maroufi systemd-sleep[5738]: Suspending system...
Sep 08 18:56:31 maroufi systemd-sleep[5738]: System resumed.
Sep 08 19:34:44 maroufi systemd-sleep[12201]: Suspending system...
Sep 09 17:23:50 maroufi systemd-sleep[12201]: System resumed.
Sep 09 17:37:38 maroufi systemd-sleep[14461]: Suspending system...
Sep 09 19:17:33 maroufi systemd-sleep[14461]: System resumed.

所以到目前为止我为解决这个问题所做的是:

  1. 转到 tty1 并输入 sudo systemctl restart lightdm.service 这很糟糕,因为它会关闭我打开的所有应用程序

  2. 我安装了 arandr 并制作了如下脚本(以 hastag 符号和 !/bin/bash 开头):

    xrandr --output eDP-1 --off --output HDMI-3 --off --output HDMI-2 --off --output HDMI-1 --off --output DP-3 --off --output DP-2 --off --output DP-1 --primary --mode 2560x1440 --pos 0x0 --rotate normal

我保存了这个脚本并设置了 ctrl+Win+P 键绑定。但这根本不起作用。

  1. 我再次进入 tty1 并从那里运行该脚本。我看到的输出是“ Can't not open display

这个问题真的很烦人,我真的想彻底摆脱它。

相关内容