Troubleshooting - LeGeRyChEeSe/Sunshine-AIO GitHub Wiki

Troubleshooting Guide

This guide addresses the most common issues reported by Sunshine-AIO users. Solutions are organized by category for easy navigation.

⚡ First Step - Try Reinstalling

Most issues are resolved by reinstalling:

Option 1: Use the "Sunshine-AIO" shortcut if already installed

Option 2: PowerShell reinstall:

# From inside Sunshine-AIO folder (Run as Administrator)
cd "path\to\Sunshine-AIO"
irm https://sunshine-aio.com/script.ps1 | iex

# OR from anywhere (you'll need to specify installation path)
irm https://sunshine-aio.com/script.ps1 | iex

Fixes automatically:

  • ✅ Missing or incorrect Python/Git versions
  • ✅ PowerShell execution policy problems
  • ✅ Missing dependencies and packages
  • ✅ Environment and permission issues

🔥 Critical Issues (High Priority)

Issue: Moonlight connects but games never start + PC stuttering

Symptoms: Connection establishes, but applications fail with "error -1", mouse becomes unresponsive during connection attempts.

Causes:

  • PowerShell script failure in setup_sunvdm.ps1
  • Display resolution mismatches
  • Virtual display driver conflicts

Solutions:

  1. Check PowerShell Execution Policy:

    Get-ExecutionPolicy
    Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
    
  2. Manual Script Test:

    cd "tools\sunshine-virtual-monitor-main"
    .\setup_sunvdm.ps1 1920 1080 60 off
    
  3. Check Virtual Display Status:

    Get-PnpDevice -Class "Display" | Where-Object {$_.FriendlyName -like "*Virtual*"}
    
  4. Reset Display Configuration:

    • Right-click Desktop → Display Settings
    • Reset to single monitor temporarily
    • Retry connection

Issue: Playnite not opening after Sunshine-AIO installation

Symptoms: Playnite launches locally but fails via Moonlight with "error 0".

Causes:

  • Global prep commands interfering with Playnite
  • Virtual display driver incompatibility
  • Incorrect app configuration in Sunshine

Solutions:

  1. Check Sunshine App Configuration:

    {
      "name": "Playnite",
      "cmd": "C:\\Program Files\\Playnite\\Playnite.FullscreenApp.exe",
      "prep-cmd": [],
      "detached": []
    }
    
  2. Disable Global Prep Commands Temporarily:

    • Sunshine Web UI → Configuration
    • Uncheck "Global Prep Commands"
    • Test Playnite streaming
  3. Manual Playnite Test:

    "C:\Program Files\Playnite\Playnite.FullscreenApp.exe"
    

Issue: Display stuck in wrong resolution after streaming

Symptoms: Monitor resolution remains incorrect after client disconnect, especially on ultrawide displays.

Causes:

  • Display reversion logic failure
  • Windows display API issues
  • Hardware-specific ultrawide problems

Solutions:

  1. Manual Display Reset:

    # Reset to original resolution
    displayswitch /extend
    displayswitch /internal
    
  2. Check Display Reversion Log:

    Sunshine logs: C:\ProgramData\Sunshine\sunshine.log
    Look for: "Failed to revert display device configuration"
    
  3. Registry Display Fix (Advanced):

    # Restart Windows Display Driver
    pnputil /restart-device "Root\BasicDisplay"
    

🛠️ Installation Issues (Medium Priority)

Issue: Installation script closes immediately

Symptoms: PowerShell window flashes and closes without visible error.

Solutions:

  1. Debug Mode:

    # From Sunshine-AIO folder or specify path when prompted
    powershell -NoExit -ExecutionPolicy Bypass
    irm https://sunshine-aio.com/script.ps1 | iex
    
  2. Check Prerequisites:

    python --version  # Should be 3.8+
    
  3. Alternative: Use "Sunshine-AIO" shortcut if already installed

Issue: Virtual Display Driver not working

Symptoms: No virtual display appears in Windows Display Settings.

Solutions:

  1. Check Installation:

    Get-PnpDevice -Class "Display" | Where-Object {$_.FriendlyName -like "*Virtual*"}
    
  2. Manual Install:

    • Navigate to tools\VDD Control\ folder
    • Run VDD Control.exe as Administrator
    • Click "Install Driver"
  3. Verify in Device Manager:

    • Look for "IDD HDR" under Display adapters
    • If missing or error, restart PC and retry

Issue: PowerShell execution blocked

Symptoms: "Execution of scripts is disabled on this system" error.

Solutions:

  1. Fix Policy (Recommended):

    # Run PowerShell as Administrator
    Set-ExecutionPolicy RemoteSigned -Scope CurrentUser
    
  2. One-time Bypass:

    powershell -ExecutionPolicy Bypass
    irm https://sunshine-aio.com/script.ps1 | iex
    

🎮 Gaming & Streaming Issues

Issue: HDR not working properly

Symptoms: HDR games appear washed out or have incorrect colors.

Solutions:

  1. Check Client HDR Support:

    • Steam Deck OLED: Full HDR support
    • Steam Deck LCD: Limited HDR
    • Other devices: Varies by hardware
  2. Enable HDR on Host:

    • Windows Settings → Display → HDR
    • Enable "Use HDR"
    • Test with HDR content first
  3. Sunshine Configuration:

    • Web UI → Configuration
    • Enable HDR options
    • Adjust HDR prep commands if needed

Issue: Applications fail with "error -1"

Symptoms: Games/apps fail to launch from Moonlight with generic error.

Solutions:

  1. Verify Application Paths:

    • Check file paths in Sunshine Web UI
    • Ensure executables exist at specified locations
    • Use absolute paths, not relative
  2. Test Manually:

    # Test the exact command from Sunshine configuration
    "C:\Program Files (x86)\Steam\steam.exe" -bigpicture
    
  3. Check Logs:

    • Location: C:\ProgramData\Sunshine\sunshine.log
    • Look for "Executing" entries and error messages
    • Common issue: Incorrect file paths or permissions

🔧 Service & Configuration Issues

Issue: Configuration lost after restart

Symptoms: Settings or applications disappear after Sunshine service restart.

Solutions:

  1. Check Configuration File:

    • Location: C:\ProgramData\Sunshine\
    • Backup config files before making changes
    • Verify JSON syntax is correct
  2. Service Test:

    # Restart Sunshine service
    net stop SunshineService
    net start SunshineService
    
  3. Permissions:

    • Ensure Sunshine service has write access to config folder
    • Run Sunshine as Administrator if needed

Issue: Display settings don't persist

Symptoms: Display configuration changes don't stick between sessions.

Solutions:

  1. Windows Display Persistence:

    # Save current display config
    displayswitch /clone
    # Apply your preferred settings
    # Windows should remember them
    
  2. Check Display Profile:

    • Windows Settings → Display → Advanced display
    • Ensure correct display profile is selected

📊 Performance Optimization

Network Optimization

Optimal Settings for 1080p:

  • Bitrate: 15-25 Mbps (adjust based on connection)
  • FPS: Match client display (usually 60)
  • Encoder: Hardware (NVENC/AMF) preferred over software

GPU Settings

NVIDIA Control Panel:

  • Power Management: "Prefer Maximum Performance"
  • Enable GPU Hardware Acceleration
  • Disable Windows GPU Scheduling if problems occur

AMD Settings:

  • Enable Hardware Acceleration
  • Set GPU to High Performance mode

System Tweaks

# Optimize for streaming performance
# Disable Game Mode if causing issues
Set-ItemProperty -Path "HKCU:\Software\Microsoft\GameBar" -Name "AutoGameModeEnabled" -Value 0

# Set High Performance power plan
powercfg.exe -s 8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c

🆘 Getting Additional Help

Collect System Information

# System info for support
systeminfo > system_info.txt
dxdiag /t dxdiag_info.txt

Sunshine Logs Location

Main log: C:\ProgramData\Sunshine\sunshine.log
Service log: Windows Event Viewer → Applications and Services → Sunshine

Before Reporting Issues

  1. Search existing issues: GitHub Issues
  2. Include logs: Sunshine logs from C:\ProgramData\Sunshine\sunshine.log
  3. System info: Windows version, GPU model, network setup
  4. Steps to reproduce: Clear instructions to recreate the problem
  5. What you tried: List troubleshooting steps already attempted

If your issue isn't covered here, please create a new issue with detailed information.