Ubuntu 20.04는 절전 모드에서 깨어난 후 모니터 해상도를 잃습니다.

Ubuntu 20.04는 절전 모드에서 깨어난 후 모니터 해상도를 잃습니다.

Nvidia RTX 3070과 Samsung C49RG90 모니터가 있습니다. 모니터는 HDMI를 통해 비디오 카드에 연결됩니다. 시스템을 일시 중단했다가 다시 깨우지 않는 한 모든 것이 잘 작동합니다. 이 경우 해상도는 1024x768로 변경됩니다. 로그인하여 Nvidia 제어판을 열고 올바른 해상도로 다시 설정할 수 있지만 다시 절전 모드로 전환하면 해상도가 항상 1024x768로 돌아갑니다.

Nvidia 드라이버 버전 470.86을 사용하고 있지만 이전 버전도 같은 방식으로 작동합니다.

wake 후 수동으로 해상도를 설정하고 실행하면 xrandr다음과 같은 결과가 나타납니다.

Screen 0: minimum 8 x 8, current 5120 x 1440, maximum 32767 x 32767
HDMI-0 connected primary 5120x1440+0+0 (normal left inverted right x axis y axis) 1mm x 1mm
   3840x1080     59.97 +
   5120x1440     59.98*   29.98  
   3840x2160     59.94    50.00    29.97    25.00    23.98  
   2560x1440     59.95  
   2560x1080     60.00    59.94  
   1920x1080     60.00    59.94    50.00  
   1680x1050     59.95  
   1600x900      60.00  
   1440x900      59.89  
   1280x1024     75.02    60.02  
   1280x800      59.81  
   1280x720      60.00    59.94    50.00  
   1152x864      75.00  
   1024x768      75.03    70.07    60.00  
   800x600       75.00    72.19    60.32    56.25  
   720x576       50.00  
   720x480       59.94  
   640x480       75.00    72.81    59.94  
DP-0 disconnected (normal left inverted right x axis y axis)
DP-1 disconnected (normal left inverted right x axis y axis)
DP-2 disconnected (normal left inverted right x axis y axis)
DP-3 disconnected (normal left inverted right x axis y axis)
DP-4 disconnected (normal left inverted right x axis y axis)
DP-5 disconnected (normal left inverted right x axis y axis)

머신을 절전 모드로 전환한 다음 다시 깨운 다음 ​​실행하면 xrandr다음과 같은 결과가 나타납니다.

Screen 0: minimum 8 x 8, current 5120 x 1440, maximum 32767 x 32767
HDMI-0 connected primary 1024x768+3327+362 (normal left inverted right x axis y axis) 0mm x 0mm panning 5120x1440+0+0
   3840x1080     59.97 +
   5120x1440     59.98    29.98  
   3840x2160     59.94    50.00    29.97    25.00    23.98  
   2560x1440     59.95  
   2560x1080     60.00    59.94  
   1920x1080     60.00    59.94    50.00  
   1680x1050     59.95  
   1600x900      60.00  
   1440x900      59.89  
   1280x1024     75.02    60.02  
   1280x800      59.81  
   1280x720      60.00    59.94    50.00  
   1152x864      75.00  
   1024x768      75.03    70.07    60.00  
   800x600       75.00    72.19    60.32    56.25  
   720x576       50.00  
   720x480       59.94  
   640x480       75.00    72.81    59.94  
DP-0 disconnected (normal left inverted right x axis y axis)
DP-1 disconnected (normal left inverted right x axis y axis)
DP-2 disconnected (normal left inverted right x axis y axis)
DP-3 disconnected (normal left inverted right x axis y axis)
DP-4 disconnected (normal left inverted right x axis y axis)
DP-5 disconnected (normal left inverted right x axis y axis)
  1024x768 (0x208) 94.500MHz +HSync +VSync
        h: width  1024 start 1072 end 1168 total 1376 skew    0 clock  68.68KHz
        v: height  768 start  769 end  772 total  808           clock  85.00Hz

xorg.conf내 파일 은 다음과 같습니다 .

# nvidia-settings: X configuration file generated by nvidia-settings
# nvidia-settings:  version 470.57.01

Section "ServerLayout"
    Identifier     "Layout0"
    Screen      0  "Screen0" 0 0
    InputDevice    "Keyboard0" "CoreKeyboard"
    InputDevice    "Mouse0" "CorePointer"
    Option         "Xinerama" "0"
EndSection

Section "Files"
EndSection

Section "Module"
    Load           "dbe"
    Load           "extmod"
    Load           "type1"
    Load           "freetype"
    Load           "glx"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol" "auto"
    Option         "Device" "/dev/psaux"
    Option         "Emulate3Buttons" "no"
    Option         "ZAxisMapping" "4 5"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Keyboard0"
    Driver         "kbd"
EndSection

Section "Monitor"
    # HorizSync source: edid, VertRefresh source: edid
    Identifier     "Monitor0"
    VendorName     "Unknown"
    ModelName      "Samsung C49RG9x"
    HorizSync       30.0 - 160.0
    VertRefresh     24.0 - 120.0
    Option         "DPMS"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "NVIDIA GeForce RTX 3070"
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "Stereo" "0"
    Option         "nvidiaXineramaInfoOrder" "DFP-0"
    Option         "metamodes" "5120x1440 +0+0; 800x600 +0+0; 640x480 +0+0"
    Option         "SLI" "Off"
    Option         "MultiGPU" "Off"
    Option         "BaseMosaic" "off"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

더 많은 정보가 필요할 것이라는 점은 이해하지만, 어디를 봐야 할지 잘 모르겠습니다.

답변1

몇 년 동안 가끔 이 문제를 조사한 끝에 문제가 해결되었다고 믿습니다.

첫 번째,이 질문Nvidia 개발자 포럼의 문제는 내 문제와 거의 동일합니다. 해당 질문의 작성자와 마찬가지로 저는 모니터가 절전 모드에서 깨어날 때 EDID 정보를 제공하지 않아 Ubuntu가 기본 1024x768 해상도를 선택하게 되는 것이 문제의 근본 원인이라고 생각합니다.

이 문제를 해결하기 위해 설명된 대로 EDID를 내보냈습니다.여기. 파일을 ASCII로 저장하고 이름을 crg-edit.txt.로 옮겼습니다 /etc/X11. 그러나 나는 그랬다~ 아니다"파일에서 디스플레이 EDID 로드" 섹션의 명령을 실행하십시오. 대신 수동으로 파일을 열고 /etc/X11/xorg.conf다음과 같이 편집했습니다(구성의 설명 참조).

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "Stereo" "0"
    Option         "nvidiaXineramaInfoOrder" "DFP-0"
    Option         "CustomEDID" "GPU-0.HDMI-0:/etc/X11/crg-edid.txt" # I added this line
    Option         "metamodes" "5120x1440 +0+0" # I removed the 1024x768 option from here
    Option         "SLI" "Off"
    Option         "MultiGPU" "Off"
    Option         "BaseMosaic" "off"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

이 단계를 수행하면 모니터가 일시 중지 상태에서 3840x1080의 더 높은 해상도로 돌아오지만 여전히 목표 해상도인 5120x1440은 아닙니다. 그래서 나는 달려가 xrandr --verbose그 결의안이 어떤 이유로 선호된다고 지적했습니다.

...
  3840x1080 (0x1be) 266.500MHz +HSync -VSync +preferred
        h: width  3840 start 3888 end 3920 total 4000 skew    0 clock  66.62KHz
        v: height 1080 start 1083 end 1093 total 1111           clock  59.97Hz
  5120x1440 (0x1bf) 469.000MHz +HSync -VSync *current
        h: width  5120 start 5168 end 5200 total 5280 skew    0 clock  88.83KHz
        v: height 1440 start 1443 end 1453 total 1481           clock  59.98Hz
...

좀 더 둘러본 끝에 발견한 것은이것질문. 그런 다음 xorg.conf다음과 같이 다시 편집했습니다 .

Section "Monitor"
    # HorizSync source: edid, VertRefresh source: edid
    Identifier     "Monitor0"
    VendorName     "Unknown"
    ModelName      "Samsung C49RG9x"
    HorizSync       30.0 - 160.0
    VertRefresh     24.0 - 120.0
    Option         "DPMS"
    Option         "PreferredMode" "5120x1440" # I added this line
EndSection

그리고

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "Stereo" "0"
    Option         "nvidiaXineramaInfoOrder" "DFP-0"
    Option         "CustomEDID" "GPU-0.HDMI-0:/etc/X11/crg-edid.txt"
    Option         "metamodes" "5120x1440 +0+0"
    Option         "SLI" "Off"
    Option         "MultiGPU" "Off"
    Option         "BaseMosaic" "off"
    SubSection     "Display"
        Virtual     5120 1440 # I added this line
        Depth       24
    EndSubSection
EndSection

사용자 정의 EDID와 기타 설정이 모두 필요한지 확실하지 않으며, 작동하고 있기 때문에 상관하지도 않습니다. 하지만 혹시라도 다른 사람에게 도움이 될까 해서 제가 알아낸 내용을 공유하고 싶었습니다.

편집: Ubuntu 22.04를 설치할 때 이 프로세스를 수행했는데 제대로 작동했습니다. 이 단계를 완료한 후 처음으로 로그인하면 화면이 기본적으로 3840x1080으로 설정됩니다. Ubuntu 제어판을 사용하여 해상도를 다시 5120x1440으로 변경했는데 재부팅 및 일시 중단을 통해 해당 설정이 유지됩니다.

답변2

나는 같은 문제가 있고 Pop!_OS 22.04를 가지고 있는데 이것은 일부 업데이트 후에 얼마 전에 시작되었습니다. 이는 드라이버 문제일 것입니다. 모니터가 다시 켜졌을 때 절전 모드로 내려갔을 때를 언급했는데 이는 모니터일 수도 있고 800x400으로 내려갈 수도 있습니다. 기본적으로 내 단계는 모니터를 껐다가 다시 켜는 것이었습니다. 내 모니터는 크리스마스에 방금 받은 27인치 Asus VQR입니다. 어떤 모니터를 첫 번째 모니터로 설정했는지에 따라 모니터가 다르기 때문에 이것이 모니터가 아니라는 것을 알고 있습니다.

저는 새로 고침 빈도와 디스플레이 해상도를 시험해 보았는데 (DP에 연결된) 모니터에는 문제가 없다고 생각합니다. 20.04를 설치하고 21.10으로 업데이트한 다음 다시 22.04로 업데이트했을 때 이런 일이 발생했습니다. 그래서 실제로 문제의 원인이 무엇인지는 모르지만, 저는 제 드라이버가 드라이버 전문가가 아니기 때문에 그동안 수정을 기다려야 할 것 같습니다.

나는 xrandr을 사용하여 컴퓨터를 시작할 때마다 모니터의 특정 해상도와 카디널리티를 설정하도록 파일을 구성할 수 있다는 것을 알고 있으며 다음에 이를 찾아서 시도해 보겠습니다. 모니터 3개를 쓰다보니 정말 이상해졌습니다.

관련 정보