Windows Server 2022 Guest Autoshutdown when Idle

Hallo @stgraber

All Windows 2022 have an issues, since windows have an idle state, windows always turn off incidental, following the logs :

[2026-08-07T22:40:14+07:00] QUERY: {"execute":"blockdev-add","arguments":{"discard":"unmap","driver":"qcow2","file":{"aio":"io_uring","cache":{"direct":true,"no-flush":false},"driver":"host_device","filename":"/dev/fdset/0"},"node-name":"incus_root","read-only":false},"id":21}
[2026-08-07T22:40:14+07:00] REPLY: {"return": {}, "id": 21}

[2026-08-07T22:40:14+07:00] QUERY: {"execute":"device_add","arguments":{"bootindex":0,"bus":"qemu_scsi.0","channel":0,"device_id":"incus_root","drive":"incus_root","driver":"scsi-hd","id":"dev-incus_root","lun":1,"serial":"incus_root"},"id":22}
[2026-08-07T22:40:14+07:00] REPLY: {"return": {}, "id": 22}

[2026-08-07T22:40:14+07:00] QUERY: {"execute":"system_reset","id":23}
[2026-08-07T22:40:14+07:00] Event: {"timestamp": {"seconds": 1786117214, "microseconds": 996789}, "event": "RESET", "data": {"guest": false, "reason": "host-qmp-system-reset"}}
[2026-08-07T22:40:14+07:00] REPLY: {"return": {}, "id": 23}

[2026-08-07T22:40:14+07:00] QUERY: {"execute":"set-action","arguments":{"panic":"exit-failure","reboot":"reset","shutdown":"poweroff"},"id":25}
[2026-08-07T22:40:15+07:00] REPLY: {"return": {}, "id": 25}

Incus version used 7.3

Best Regards
Dwi

stgraber@vorash-d13:~ (incus:dev-cluster02/migration)$ incus info windows-2022
Name: windows-2022
Description: Auto-imported from VMware
Status: RUNNING
Type: virtual-machine
Architecture: x86_64
Location: entak
PID: 5585
Created: 2026/05/29 04:11 EDT
Last Used: 2026/08/04 16:12 EDT
Started: 2026/08/04 16:12 EDT

Operating System:
  OS: Windows Server 2022 Datacenter Evaluation
  OS Version: 20348
  Kernel Version: 6.3
  Hostname: WIN-VTG1I50FBTQ
  FQDN: WIN-VTG1I50FBTQ

Resources:
  Processes: 76
  Disk usage:
    root: 9.65GiB
  CPU usage:
    CPU usage (in seconds): 820
  Memory usage:
    Memory (current): 1.53GiB
  Network usage:
    Ethernet0:
      Type: broadcast
      State: UP
      Host interface: Ethernet0
      MAC address: 00:50:56:a9:d5:47
      MTU: 1500
      Bytes received: 95.63MB
      Bytes sent: 5.34MB
      Packets received: 58808
      Packets sent: 25240
      IP addresses:
        inet6: 2602:fc62:c:1045:1cd9:bdb0:1b55:7ec3/64 (global)
        inet6: fe80::1cd9:bdb0:1b55:7ec3/64 (link)
        inet:  172.17.45.230/24 (global)
    Loopback Pseudo-Interface 1:
      Type: loopback
      State: UP
      Host interface: Loopback Pseudo-Interface 1
      MTU: -1
      Bytes received: 0B
      Bytes sent: 0B
      Packets received: 0
      Packets sent: 0
      IP addresses:
        inet6: ::1/128 (local)
        inet:  127.0.0.1/8 (local)
stgraber@vorash-d13:~ (incus:dev-cluster02/migration)$ incus exec windows-2022 -T powershell
Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.

Install the latest PowerShell for new features and improvements! https://aka.ms/PSWindows

PS C:\WINDOWS\System32> (Get-CimInstance Win32_OperatingSystem).LastBootUpTime
(Get-CimInstance Win32_OperatingSystem).LastBootUpTime

Tuesday, August 4, 2026 1:12:42 PM


PS C:\WINDOWS\System32> 

Been running for 3 days straight and is a completely unused VM.

It’s interesting. if I install Windows from an ISO and run it, nothing happens; it doesn’t auto-shutdown even when idle. However, when I turn that installed Windows instance into a published template and then create a VM from it, it auto-shuts down when idle.

Did you go through sysprep before publishing?

I wonder if it’s Windows freaking out because it’s running on unexpected hardware or seeing a duplicate system on the network.