Skip to content

Entire system hangs if system enters sleep mode from being AFK #5366

Description

@BlannyBlannyBlanc

Is there an existing issue for this?

  • I have searched the existing issues

Is your issue described in the documentation?

  • I have read the documentation

Is your issue present in the latest beta/pre-release?

This issue is present in the latest pre-release

Describe the Bug

If you start a fullscreen game, and by some odds, Windows turns the monitors off due to inactivity, the entire system will hang. I left Sunshine on last night for my partner to play a game remotely through my PC, and when I woke up this morning my system was completely unresponsive (keyboard was stuck, couldn't toggle capslock, nothing worked) and had to manually power off and reboot. Upon reboot system was fine.

It would seem that if a game is in fullscreen, being streamed and Windows places the monitors in standby the system freaks out, and hangs.

Expected Behavior

When Windows initiates monitor power-saving mode (standby) while a game is running in fullscreen and being remotely streamed via Sunshine, the system should either:

  • Suppreess the sleep timer due to active user input/video streaming activity, keeping the monitors awake.

  • Gracefully handle the display state change by allowing the game and Sunshine encoder to continue running headlessly, or cleanly pausing the stream, without causing a kernel-level driver crash or hard system freeze.

Additional Context

  • My setup is using dual DisplayPort Monitors
  • I was streaming a fullscreen DX11 game at the time before falling asleep with my PC still on
  • It's a complete low-level system hang, nothing responds, requiring a hard reset
  • Using a virtual display driver might be able to help correct this

Host Operating System

Windows

Operating System Version

Windows 10 [10.0.19045.7417]

Architecture

amd64/x86_64

Package

Windows - msi installer (recommended)

GPU Type

NVIDIA

GPU Model

3060 RTX (12GB)

GPU Driver/Mesa Version

32.0.15.9636

Capture Method

Windows.Graphics.Capture (Windows)

Apps

Log output

[2026-07-02 08:33:08.791]: Info: Sunshine version: 2026.619.155209 commit: 1fce18d99a1dfc925b501a6a9b8bc280b6675fc5
[2026-07-02 08:33:08.791]: Info: Package Publisher: LizardByte
[2026-07-02 08:33:08.791]: Info: Publisher Website: https://app.lizardbyte.dev
[2026-07-02 08:33:08.791]: Info: Get support: https://app.lizardbyte.dev/support
[2026-07-02 08:33:08.791]: Info: config: 'address_family' = both
[2026-07-02 08:33:08.791]: Info: config: 'audio_sink' = CABLE-A Input (VB-Audio Cable A)
[2026-07-02 08:33:08.791]: Info: config: 'install_steam_audio_drivers' = disabled
[2026-07-02 08:33:08.791]: Info: config: 'origin_web_ui_allowed' = pc
[2026-07-02 08:33:08.791]: Info: config: 'output_name' = {cf340bb7-1c42-59e5-b024-f56b975f9cf5}
[2026-07-02 08:33:08.791]: Info: config: 'upnp' = enabled
[2026-07-02 08:33:08.791]: Info: config: 'virtual_sink' = VB-Audio Cable A
[2026-07-02 08:33:08.791]: Info: Provided workaround settings for SettingsManager:
{
  "hdr_blank_delay": null
}
[2026-07-02 08:33:08.796]: Info: Currently available display devices:
[
  {
    "device_id": "{cf340bb7-1c42-59e5-b024-f56b975f9cf5}",
    "display_name": "\\\\.\\DISPLAY1",
    "edid": {
      "manufacturer_id": "MSI",
      "product_code": "3DE0",
      "serial_number": 16843009
    },
    "friendly_name": "MAG 321CQ E18",
    "info": {
      "hdr_state": "Enabled",
      "origin_point": {
        "x": 0,
        "y": 0
      },
      "primary": true,
      "refresh_rate": {
        "type": "rational",
        "value": {
          "denominator": 1000,
          "numerator": 119998
        }
      },
      "resolution": {
        "height": 1440,
        "width": 2560
      },
      "resolution_scale": {
        "type": "rational",
        "value": {
          "denominator": 100,
          "numerator": 100
        }
      }
    }
  }
]
[2026-07-02 08:33:09.139]: Info: nvprefs: Opened undo file from previous improper termination
[2026-07-02 08:33:09.140]: Info: nvprefs: Restored OGL_CPL_PREFER_DXPRESENT for base profile
[2026-07-02 08:33:09.181]: Info: nvprefs: Restored global profile settings from undo file - deleting the file
[2026-07-02 08:33:09.183]: Info: nvprefs: No need to modify application profile settings
[2026-07-02 08:33:09.183]: Info: nvprefs: Changed OGL_CPL_PREFER_DXPRESENT to OGL_CPL_PREFER_DXPRESENT_PREFER_ENABLED for base profile
[2026-07-02 08:33:09.304]: Info: Compiling shaders...
[2026-07-02 08:33:09.780]: Info: Compiled shaders
[2026-07-02 08:33:09.802]: Info: // Testing for available encoders, this may generate errors. You can safely ignore those errors. //
[2026-07-02 08:33:09.803]: Info: Trying encoder [nvenc]
[2026-07-02 08:33:10.394]: Info: 
Device Description : NVIDIA GeForce RTX 3060
Device Vendor ID   : 0x000010DE
Device Device ID   : 0x00002503
Device Video Mem   : 12115 MiB
Device Sys Mem     : 0 MiB
Share Sys Mem      : 32718 MiB
Feature Level      : 0x0000B100
Capture size       : 2560x1440
Offset             : 0x0
Virtual Desktop    : 2560x1440
[2026-07-02 08:33:10.394]: Info: Active GPU has HAGS enabled
[2026-07-02 08:33:10.394]: Info: Using realtime GPU priority
[2026-07-02 08:33:10.395]: Info: 
Colorspace         : DXGI_COLOR_SPACE_RGB_FULL_G2084_NONE_P2020
Bits Per Color     : 10
Red Primary        : [0.670898,0.310547]
Green Primary      : [0.283203,0.642578]
Blue Primary       : [0.154297,0.0527344]
White Point        : [0.313477,0.329102]
Min Luminance      : 0.0362 nits
Max Luminance      : 301.849 nits
Max Full Luminance : 301.849 nits
[2026-07-02 08:33:10.395]: Info: Desktop resolution [2560x1440]
[2026-07-02 08:33:10.395]: Info: Desktop format [DXGI_FORMAT_R16G16B16A16_FLOAT]
[2026-07-02 08:33:10.395]: Info: Display refresh rate [119.998Hz]
[2026-07-02 08:33:10.395]: Info: Requested frame rate [60/1 exactly 60 fps]
[2026-07-02 08:33:10.396]: Info: Creating encoder [h264_nvenc]
[2026-07-02 08:33:10.396]: Info: Color coding: SDR (Rec. 601)
[2026-07-02 08:33:10.396]: Info: Color depth: 8-bit
[2026-07-02 08:33:10.396]: Info: Color range: JPEG
[2026-07-02 08:33:10.463]: Info: NvEnc: created encoder H.264 P1 async two-pass rfi
[2026-07-02 08:33:10.488]: Info: Creating encoder [hevc_nvenc]
[2026-07-02 08:33:10.488]: Info: Color coding: SDR (Rec. 601)
[2026-07-02 08:33:10.488]: Info: Color depth: 8-bit
[2026-07-02 08:33:10.488]: Info: Color range: JPEG
[2026-07-02 08:33:10.543]: Info: NvEnc: created encoder HEVC P1 async two-pass rfi
[2026-07-02 08:33:10.569]: Info: Creating encoder [av1_nvenc]
[2026-07-02 08:33:10.569]: Info: Color coding: SDR (Rec. 601)
[2026-07-02 08:33:10.569]: Info: Color depth: 8-bit
[2026-07-02 08:33:10.569]: Info: Color range: JPEG
[2026-07-02 08:33:10.599]: Error: NvEnc: encoding format is not supported by the gpu
[2026-07-02 08:33:10.600]: Error: NvEnc: NvEncUnregisterAsyncEvent() failed: NV_ENC_ERR_DEVICE_NOT_EXIST
[2026-07-02 08:33:10.963]: Info: 
Device Description : NVIDIA GeForce RTX 3060
Device Vendor ID   : 0x000010DE
Device Device ID   : 0x00002503
Device Video Mem   : 12115 MiB
Device Sys Mem     : 0 MiB
Share Sys Mem      : 32718 MiB
Feature Level      : 0x0000B100
Capture size       : 2560x1440
Offset             : 0x0
Virtual Desktop    : 2560x1440
[2026-07-02 08:33:10.963]: Info: Active GPU has HAGS enabled
[2026-07-02 08:33:10.963]: Info: Using realtime GPU priority
[2026-07-02 08:33:10.963]: Info: 
Colorspace         : DXGI_COLOR_SPACE_RGB_FULL_G2084_NONE_P2020
Bits Per Color     : 10
Red Primary        : [0.670898,0.310547]
Green Primary      : [0.283203,0.642578]
Blue Primary       : [0.154297,0.0527344]
White Point        : [0.313477,0.329102]
Min Luminance      : 0.0362 nits
Max Luminance      : 301.849 nits
Max Full Luminance : 301.849 nits
[2026-07-02 08:33:10.963]: Info: Desktop resolution [2560x1440]
[2026-07-02 08:33:10.964]: Info: Desktop format [DXGI_FORMAT_R16G16B16A16_FLOAT]
[2026-07-02 08:33:10.964]: Info: Display refresh rate [119.998Hz]
[2026-07-02 08:33:10.964]: Info: Requested frame rate [60/1 exactly 60 fps]
[2026-07-02 08:33:10.964]: Info: Creating encoder [h264_nvenc]
[2026-07-02 08:33:10.964]: Info: Color coding: SDR (Rec. 601)
[2026-07-02 08:33:10.964]: Info: Color depth: 8-bit
[2026-07-02 08:33:10.964]: Info: Color range: JPEG
[2026-07-02 08:33:11.018]: Info: NvEnc: created encoder H.264 P1 async yuv444 two-pass rfi
[2026-07-02 08:33:11.419]: Info: 
Device Description : NVIDIA GeForce RTX 3060
Device Vendor ID   : 0x000010DE
Device Device ID   : 0x00002503
Device Video Mem   : 12115 MiB
Device Sys Mem     : 0 MiB
Share Sys Mem      : 32718 MiB
Feature Level      : 0x0000B100
Capture size       : 2560x1440
Offset             : 0x0
Virtual Desktop    : 2560x1440
[2026-07-02 08:33:11.419]: Info: Active GPU has HAGS enabled
[2026-07-02 08:33:11.419]: Info: Using realtime GPU priority
[2026-07-02 08:33:11.420]: Info: 
Colorspace         : DXGI_COLOR_SPACE_RGB_FULL_G2084_NONE_P2020
Bits Per Color     : 10
Red Primary        : [0.670898,0.310547]
Green Primary      : [0.283203,0.642578]
Blue Primary       : [0.154297,0.0527344]
White Point        : [0.313477,0.329102]
Min Luminance      : 0.0362 nits
Max Luminance      : 301.849 nits
Max Full Luminance : 301.849 nits
[2026-07-02 08:33:11.420]: Info: Desktop resolution [2560x1440]
[2026-07-02 08:33:11.420]: Info: Desktop format [DXGI_FORMAT_R16G16B16A16_FLOAT]
[2026-07-02 08:33:11.420]: Info: Display refresh rate [119.998Hz]
[2026-07-02 08:33:11.420]: Info: Requested frame rate [60/1 exactly 60 fps]
[2026-07-02 08:33:11.420]: Info: Creating encoder [hevc_nvenc]
[2026-07-02 08:33:11.421]: Info: Color coding: SDR (Rec. 601)
[2026-07-02 08:33:11.421]: Info: Color depth: 8-bit
[2026-07-02 08:33:11.421]: Info: Color range: JPEG
[2026-07-02 08:33:11.482]: Info: NvEnc: created encoder HEVC P1 async yuv444 two-pass rfi
[2026-07-02 08:33:11.961]: Info: 
Device Description : NVIDIA GeForce RTX 3060
Device Vendor ID   : 0x000010DE
Device Device ID   : 0x00002503
Device Video Mem   : 12115 MiB
Device Sys Mem     : 0 MiB
Share Sys Mem      : 32718 MiB
Feature Level      : 0x0000B100
Capture size       : 2560x1440
Offset             : 0x0
Virtual Desktop    : 2560x1440
[2026-07-02 08:33:11.961]: Info: Active GPU has HAGS enabled
[2026-07-02 08:33:11.961]: Info: Using realtime GPU priority
[2026-07-02 08:33:11.961]: Info: 
Colorspace         : DXGI_COLOR_SPACE_RGB_FULL_G2084_NONE_P2020
Bits Per Color     : 10
Red Primary        : [0.670898,0.310547]
Green Primary      : [0.283203,0.642578]
Blue Primary       : [0.154297,0.0527344]
White Point        : [0.313477,0.329102]
Min Luminance      : 0.0362 nits
Max Luminance      : 301.849 nits
Max Full Luminance : 301.849 nits
[2026-07-02 08:33:11.961]: Info: Desktop resolution [2560x1440]
[2026-07-02 08:33:11.961]: Info: Desktop format [DXGI_FORMAT_R16G16B16A16_FLOAT]
[2026-07-02 08:33:11.961]: Info: Display refresh rate [119.998Hz]
[2026-07-02 08:33:11.961]: Info: Requested frame rate [60/1 exactly 60 fps]
[2026-07-02 08:33:11.962]: Info: Creating encoder [hevc_nvenc]
[2026-07-02 08:33:11.962]: Info: Color coding: HDR (Rec. 2020 + SMPTE 2084 PQ)
[2026-07-02 08:33:11.962]: Info: Color depth: 10-bit
[2026-07-02 08:33:11.962]: Info: Color range: JPEG
[2026-07-02 08:33:12.011]: Info: NvEnc: created encoder HEVC P1 async 10-bit two-pass rfi
[2026-07-02 08:33:12.408]: Info: 
Device Description : NVIDIA GeForce RTX 3060
Device Vendor ID   : 0x000010DE
Device Device ID   : 0x00002503
Device Video Mem   : 12115 MiB
Device Sys Mem     : 0 MiB
Share Sys Mem      : 32718 MiB
Feature Level      : 0x0000B100
Capture size       : 2560x1440
Offset             : 0x0
Virtual Desktop    : 2560x1440
[2026-07-02 08:33:12.408]: Info: Active GPU has HAGS enabled
[2026-07-02 08:33:12.408]: Info: Using realtime GPU priority
[2026-07-02 08:33:12.408]: Info: 
Colorspace         : DXGI_COLOR_SPACE_RGB_FULL_G2084_NONE_P2020
Bits Per Color     : 10
Red Primary        : [0.670898,0.310547]
Green Primary      : [0.283203,0.642578]
Blue Primary       : [0.154297,0.0527344]
White Point        : [0.313477,0.329102]
Min Luminance      : 0.0362 nits
Max Luminance      : 301.849 nits
Max Full Luminance : 301.849 nits
[2026-07-02 08:33:12.409]: Info: Desktop resolution [2560x1440]
[2026-07-02 08:33:12.409]: Info: Desktop format [DXGI_FORMAT_R16G16B16A16_FLOAT]
[2026-07-02 08:33:12.409]: Info: Display refresh rate [119.998Hz]
[2026-07-02 08:33:12.409]: Info: Requested frame rate [60/1 exactly 60 fps]
[2026-07-02 08:33:12.409]: Info: Creating encoder [hevc_nvenc]
[2026-07-02 08:33:12.409]: Info: Color coding: HDR (Rec. 2020 + SMPTE 2084 PQ)
[2026-07-02 08:33:12.409]: Info: Color depth: 10-bit
[2026-07-02 08:33:12.409]: Info: Color range: JPEG
[2026-07-02 08:33:12.633]: Info: NvEnc: created encoder HEVC P1 async yuv444 10-bit two-pass rfi
[2026-07-02 08:33:13.469]: Info: 
Device Description : NVIDIA GeForce RTX 3060
Device Vendor ID   : 0x000010DE
Device Device ID   : 0x00002503
Device Video Mem   : 12115 MiB
Device Sys Mem     : 0 MiB
Share Sys Mem      : 32718 MiB
Feature Level      : 0x0000B100
Capture size       : 2560x1440
Offset             : 0x0
Virtual Desktop    : 2560x1440
[2026-07-02 08:33:13.469]: Info: Active GPU has HAGS enabled
[2026-07-02 08:33:13.469]: Info: Using realtime GPU priority
[2026-07-02 08:33:13.469]: Info: 
Colorspace         : DXGI_COLOR_SPACE_RGB_FULL_G2084_NONE_P2020
Bits Per Color     : 10
Red Primary        : [0.670898,0.310547]
Green Primary      : [0.283203,0.642578]
Blue Primary       : [0.154297,0.0527344]
White Point        : [0.313477,0.329102]
Min Luminance      : 0.0362 nits
Max Luminance      : 301.849 nits
Max Full Luminance : 301.849 nits
[2026-07-02 08:33:13.470]: Info: Desktop resolution [2560x1440]
[2026-07-02 08:33:13.470]: Info: Desktop format [DXGI_FORMAT_R16G16B16A16_FLOAT]
[2026-07-02 08:33:13.470]: Info: Display refresh rate [119.998Hz]
[2026-07-02 08:33:13.470]: Info: Requested frame rate [60/1 exactly 60 fps]
[2026-07-02 08:33:13.896]: Info: 
Device Description : NVIDIA GeForce RTX 3060
Device Vendor ID   : 0x000010DE
Device Device ID   : 0x00002503
Device Video Mem   : 12115 MiB
Device Sys Mem     : 0 MiB
Share Sys Mem      : 32718 MiB
Feature Level      : 0x0000B100
Capture size       : 2560x1440
Offset             : 0x0
Virtual Desktop    : 2560x1440
[2026-07-02 08:33:13.896]: Info: Active GPU has HAGS enabled
[2026-07-02 08:33:13.896]: Info: Using realtime GPU priority
[2026-07-02 08:33:13.897]: Info: 
Colorspace         : DXGI_COLOR_SPACE_RGB_FULL_G2084_NONE_P2020
Bits Per Color     : 10
Red Primary        : [0.670898,0.310547]
Green Primary      : [0.283203,0.642578]
Blue Primary       : [0.154297,0.0527344]
White Point        : [0.313477,0.329102]
Min Luminance      : 0.0362 nits
Max Luminance      : 301.849 nits
Max Full Luminance : 301.849 nits
[2026-07-02 08:33:13.897]: Info: Desktop resolution [2560x1440]
[2026-07-02 08:33:13.898]: Info: Desktop format [DXGI_FORMAT_R16G16B16A16_FLOAT]
[2026-07-02 08:33:13.898]: Info: Display refresh rate [119.998Hz]
[2026-07-02 08:33:13.898]: Info: Requested frame rate [60/1 exactly 60 fps]
[2026-07-02 08:33:14.326]: Info: 
Device Description : NVIDIA GeForce RTX 3060
Device Vendor ID   : 0x000010DE
Device Device ID   : 0x00002503
Device Video Mem   : 12115 MiB
Device Sys Mem     : 0 MiB
Share Sys Mem      : 32718 MiB
Feature Level      : 0x0000B100
Capture size       : 2560x1440
Offset             : 0x0
Virtual Desktop    : 2560x1440
[2026-07-02 08:33:14.327]: Info: Active GPU has HAGS enabled
[2026-07-02 08:33:14.327]: Info: Using realtime GPU priority
[2026-07-02 08:33:14.327]: Info: 
Colorspace         : DXGI_COLOR_SPACE_RGB_FULL_G2084_NONE_P2020
Bits Per Color     : 10
Red Primary        : [0.670898,0.310547]
Green Primary      : [0.283203,0.642578]
Blue Primary       : [0.154297,0.0527344]
White Point        : [0.313477,0.329102]
Min Luminance      : 0.0362 nits
Max Luminance      : 301.849 nits
Max Full Luminance : 301.849 nits
[2026-07-02 08:33:14.327]: Info: Desktop resolution [2560x1440]
[2026-07-02 08:33:14.327]: Info: Desktop format [DXGI_FORMAT_R16G16B16A16_FLOAT]
[2026-07-02 08:33:14.327]: Info: Display refresh rate [119.998Hz]
[2026-07-02 08:33:14.327]: Info: Requested frame rate [60/1 exactly 60 fps]
[2026-07-02 08:33:14.342]: Info: 
[2026-07-02 08:33:14.342]: Info: // Ignore any errors mentioned above, they are not relevant. //
[2026-07-02 08:33:14.342]: Info: 
[2026-07-02 08:33:14.342]: Info: Found H.264 encoder: h264_nvenc [nvenc]
[2026-07-02 08:33:14.342]: Info: Found HEVC encoder: hevc_nvenc [nvenc]
[2026-07-02 08:33:14.353]: Info: Starting system tray
[2026-07-02 08:33:14.353]: Info: System tray thread initialized successfully
[2026-07-02 08:33:14.353]: Info: No main thread features enabled, skipping event loop
[2026-07-02 08:33:14.353]: Info: System tray thread started
[2026-07-02 08:33:14.371]: Info: Configuration UI available at [https://localhost:47990]
[2026-07-02 08:33:14.464]: Info: System tray created
[2026-07-02 08:33:15.140]: Info: Registered Sunshine mDNS service
[2026-07-02 08:33:22.396]: Warning: Couldn't discover any IPv4 UPNP devices
[2026-07-02 08:33:30.349]: Info: Opening UI from system tray
[2026-07-02 08:33:30.364]: Info: Resolved user-provided command 'https://localhost:47990' to '"C:\Program Files\Mozilla Firefox Beta\firefox.exe" -osint -url "https://localhost:47990"'
[2026-07-02 08:33:30.370]: Info: https://localhost:47990 running with PID 18844
[2026-07-02 08:33:30.370]: Info: Opened url [https://localhost:47990]
[2026-07-02 08:33:30.572]: Info: Web UI: [127.0.0.1] -- not authorized
[2026-07-02 08:35:30.427]: Warning: Couldn't discover any IPv4 UPNP devices
[2026-07-02 08:37:38.496]: Warning: Couldn't discover any IPv4 UPNP devices
[2026-07-02 08:39:46.531]: Warning: Couldn't discover any IPv4 UPNP devices
[2026-07-02 08:41:54.589]: Warning: Couldn't discover any IPv4 UPNP devices
[2026-07-02 08:44:02.655]: Warning: Couldn't discover any IPv4 UPNP devices
[2026-07-02 08:46:10.709]: Warning: Couldn't discover any IPv4 UPNP devices
[2026-07-02 08:48:18.753]: Warning: Couldn't discover any IPv4 UPNP devices
[2026-07-02 08:50:26.799]: Warning: Couldn't discover any IPv4 UPNP devices
[2026-07-02 08:52:34.851]: Warning: Couldn't discover any IPv4 UPNP devices
[2026-07-02 08:54:42.872]: Warning: Couldn't discover any IPv4 UPNP devices
[2026-07-02 08:56:50.917]: Warning: Couldn't discover any IPv4 UPNP devices
[2026-07-02 08:57:33.796]: Info: Opening UI from system tray
[2026-07-02 08:57:33.798]: Info: Resolved user-provided command 'https://localhost:47990' to '"C:\Program Files\Mozilla Firefox\firefox.exe" -osint -url "https://localhost:47990"'
[2026-07-02 08:57:33.803]: Info: https://localhost:47990 running with PID 3220
[2026-07-02 08:57:33.803]: Info: Opened url [https://localhost:47990]

Online logs

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions