Windows VM keeps shutting down automatically

CheeryFlame

Contributor
Joined
Nov 21, 2022
Messages
184
Hello,

I just created my first Windows virtual machine and it keeps shutting down. I'm not an expert and new to virtualisation.

Virtual CPUs:​

2

Cores:​

4

Threads:​

2

Memory Size:​

4.00 GiB

Boot Loader Type:​

UEFI

System Clock:​

LOCAL

Display Port:​

5900

Description:​

N/A

Shutdown Timeout:​

90 seconds

Code:
2023-09-07 20:14:06.978+0000: starting up libvirt version: 7.0.0, package: 3 (Andrea Bolognani <eof@kiyuko.org> Fri, 26 Feb 2021 16:46:34 +0100), qemu version: 5.2.0Debian 1:5.2+dfsg-11+deb11u2, kernel: 5.15.107+truenas, hostname: TrueNAS.local
LC_ALL=C \
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \
HOME=/var/lib/libvirt/qemu/domain-1-5_Windows_10_Enterpr \
XDG_DATA_HOME=/var/lib/libvirt/qemu/domain-1-5_Windows_10_Enterpr/.local/share \
XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain-1-5_Windows_10_Enterpr/.cache \
XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain-1-5_Windows_10_Enterpr/.config \
QEMU_AUDIO_DRV=none \
/usr/bin/qemu-system-x86_64 \
-name guest=5_Windows_10_Enterprise_LTSC_2021,debug-threads=on \
-S \
-object secret,id=masterKey0,format=raw,file=/var/lib/libvirt/qemu/domain-1-5_Windows_10_Enterpr/master-key.aes \
-blockdev '{"driver":"file","filename":"/usr/share/OVMF/OVMF_CODE.fd","node-name":"libvirt-pflash0-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-pflash0-format","read-only":true,"driver":"raw","file":"libvirt-pflash0-storage"}' \
-blockdev '{"driver":"file","filename":"/var/lib/libvirt/qemu/nvram/5_Windows_10_Enterprise_LTSC_2021_VARS.fd","node-name":"libvirt-pflash1-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-pflash1-format","read-only":false,"driver":"raw","file":"libvirt-pflash1-storage"}' \
-machine pc-i440fx-5.2,accel=kvm,usb=off,dump-guest-core=off,pflash0=libvirt-pflash0-format,pflash1=libvirt-pflash1-format,memory-backend=pc.ram \
-cpu qemu64 \
-m 8192 \
-object memory-backend-ram,id=pc.ram,size=8589934592 \
-overcommit mem-lock=off \
-smp 64,sockets=2,dies=1,cores=8,threads=4 \
-uuid ae88a148-3f3a-40b3-b51b-4058d086d65f \
-no-user-config \
-nodefaults \
-chardev socket,id=charmonitor,fd=34,server,nowait \
-mon chardev=charmonitor,id=monitor,mode=control \
-rtc base=localtime \
-no-shutdown \
-boot strict=on \
-device nec-usb-xhci,id=usb,bus=pci.0,addr=0x4 \
-device ahci,id=sata0,bus=pci.0,addr=0x5 \
-device virtio-serial-pci,id=virtio-serial0,bus=pci.0,addr=0x6 \
-blockdev '{"driver":"file","filename":"/mnt/Eden/Applications/ISOs/19044.1288.211006-0501.21h2_release_svc_refresh_CLIENT_LTSC_EVAL_x64FRE_en-us.iso","node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-2-format","read-only":true,"driver":"raw","file":"libvirt-2-storage"}' \
-device ide-cd,bus=sata0.0,drive=libvirt-2-format,id=sata0-0-0,bootindex=1 \
-blockdev '{"driver":"host_device","filename":"/dev/zvol/Pollen/vms/Windows_10_Enterprise_LTSC_2021-jfc398","aio":"threads","node-name":"libvirt-1-storage","cache":{"direct":true,"no-flush":false},"auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-1-format","read-only":false,"cache":{"direct":true,"no-flush":false},"driver":"raw","file":"libvirt-1-storage"}' \
-device ide-hd,bus=sata0.1,drive=libvirt-1-format,id=sata0-0-1,bootindex=2,write-cache=on \
-netdev tap,fd=37,id=hostnet0 \
-device e1000,netdev=hostnet0,id=net0,mac=00:a0:98:4c:0c:db,bus=pci.0,addr=0x3 \
-chardev pty,id=charserial0 \
-device isa-serial,chardev=charserial0,id=serial0 \
-chardev socket,id=charchannel0,fd=38,server,nowait \
-device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=org.qemu.guest_agent.0 \
-device usb-tablet,id=input0,bus=usb.0,port=1 \
-vnc 10.0.10.13:0 \
-device qxl-vga,id=video0,ram_size=67108864,vram_size=67108864,vram64_size_mb=0,vgamem_mb=16,max_outputs=1,xres=1024,yres=768,bus=pci.0,addr=0x2 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x7 \
-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \
-msg timestamp=on
char device redirected to /dev/pts/6 (label charserial0)
2023-09-07T20:16:20.080788Z qemu-system-x86_64: terminating on signal 15 from pid 3328220 (/usr/sbin/libvirtd)
2023-09-07 20:16:20.281+0000: shutting down, reason=destroyed
2023-09-07 20:16:34.572+0000: starting up libvirt version: 7.0.0, package: 3 (Andrea Bolognani <eof@kiyuko.org> Fri, 26 Feb 2021 16:46:34 +0100), qemu version: 5.2.0Debian 1:5.2+dfsg-11+deb11u2, kernel: 5.15.107+truenas, hostname: TrueNAS.local
LC_ALL=C \
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \
HOME=/var/lib/libvirt/qemu/domain-2-5_Windows_10_Enterpr \
XDG_DATA_HOME=/var/lib/libvirt/qemu/domain-2-5_Windows_10_Enterpr/.local/share \
XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain-2-5_Windows_10_Enterpr/.cache \
XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain-2-5_Windows_10_Enterpr/.config \
QEMU_AUDIO_DRV=none \
/usr/bin/qemu-system-x86_64 \
-name guest=5_Windows_10_Enterprise_LTSC_2021,debug-threads=on \
-S \
-object secret,id=masterKey0,format=raw,file=/var/lib/libvirt/qemu/domain-2-5_Windows_10_Enterpr/master-key.aes \
-blockdev '{"driver":"file","filename":"/usr/share/OVMF/OVMF_CODE.fd","node-name":"libvirt-pflash0-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-pflash0-format","read-only":true,"driver":"raw","file":"libvirt-pflash0-storage"}' \
-blockdev '{"driver":"file","filename":"/var/lib/libvirt/qemu/nvram/5_Windows_10_Enterprise_LTSC_2021_VARS.fd","node-name":"libvirt-pflash1-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-pflash1-format","read-only":false,"driver":"raw","file":"libvirt-pflash1-storage"}' \
-machine pc-i440fx-5.2,accel=kvm,usb=off,dump-guest-core=off,pflash0=libvirt-pflash0-format,pflash1=libvirt-pflash1-format,memory-backend=pc.ram \
-cpu qemu64 \
-m 8192 \
-object memory-backend-ram,id=pc.ram,size=8589934592 \
-overcommit mem-lock=off \
-smp 64,sockets=2,dies=1,cores=8,threads=4 \
-uuid ae88a148-3f3a-40b3-b51b-4058d086d65f \
-no-user-config \
-nodefaults \
-chardev socket,id=charmonitor,fd=34,server,nowait \
-mon chardev=charmonitor,id=monitor,mode=control \
-rtc base=localtime \
-no-shutdown \
-boot strict=on \
-device nec-usb-xhci,id=usb,bus=pci.0,addr=0x4 \
-device ahci,id=sata0,bus=pci.0,addr=0x5 \
-device virtio-serial-pci,id=virtio-serial0,bus=pci.0,addr=0x6 \
-blockdev '{"driver":"file","filename":"/mnt/Eden/Applications/ISOs/19044.1288.211006-0501.21h2_release_svc_refresh_CLIENT_LTSC_EVAL_x64FRE_en-us.iso","node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-2-format","read-only":true,"driver":"raw","file":"libvirt-2-storage"}' \
-device ide-cd,bus=sata0.0,drive=libvirt-2-format,id=sata0-0-0,bootindex=1 \
-blockdev '{"driver":"host_device","filename":"/dev/zvol/Pollen/vms/Windows_10_Enterprise_LTSC_2021-jfc398","aio":"threads","node-name":"libvirt-1-storage","cache":{"direct":true,"no-flush":false},"auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-1-format","read-only":false,"cache":{"direct":true,"no-flush":false},"driver":"raw","file":"libvirt-1-storage"}' \
-device ide-hd,bus=sata0.1,drive=libvirt-1-format,id=sata0-0-1,bootindex=2,write-cache=on \
-netdev tap,fd=37,id=hostnet0 \
-device e1000,netdev=hostnet0,id=net0,mac=00:a0:98:4c:0c:db,bus=pci.0,addr=0x3 \
-chardev pty,id=charserial0 \
-device isa-serial,chardev=charserial0,id=serial0 \
-chardev socket,id=charchannel0,fd=38,server,nowait \
-device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=org.qemu.guest_agent.0 \
-device usb-tablet,id=input0,bus=usb.0,port=1 \
-vnc 10.0.10.13:0 \
-device qxl-vga,id=video0,ram_size=67108864,vram_size=67108864,vram64_size_mb=0,vgamem_mb=16,max_outputs=1,xres=1600,yres=900,bus=pci.0,addr=0x2 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x7 \
-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \
-msg timestamp=on
char device redirected to /dev/pts/6 (label charserial0)
2023-09-07T21:27:07.572628Z qemu-system-x86_64: terminating on signal 15 from pid 3328220 (/usr/sbin/libvirtd)
2023-09-07 21:27:08.807+0000: shutting down, reason=shutdown
2023-09-07 21:48:23.489+0000: starting up libvirt version: 7.0.0, package: 3 (Andrea Bolognani <eof@kiyuko.org> Fri, 26 Feb 2021 16:46:34 +0100), qemu version: 5.2.0Debian 1:5.2+dfsg-11+deb11u2, kernel: 5.15.107+truenas, hostname: TrueNAS.local
LC_ALL=C \
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \
HOME=/var/lib/libvirt/qemu/domain-3-5_Windows_10_Enterpr \
XDG_DATA_HOME=/var/lib/libvirt/qemu/domain-3-5_Windows_10_Enterpr/.local/share \
XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain-3-5_Windows_10_Enterpr/.cache \
XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain-3-5_Windows_10_Enterpr/.config \
QEMU_AUDIO_DRV=none \
/usr/bin/qemu-system-x86_64 \
-name guest=5_Windows_10_Enterprise_LTSC_2021,debug-threads=on \
-S \
-object secret,id=masterKey0,format=raw,file=/var/lib/libvirt/qemu/domain-3-5_Windows_10_Enterpr/master-key.aes \
-blockdev '{"driver":"file","filename":"/usr/share/OVMF/OVMF_CODE.fd","node-name":"libvirt-pflash0-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-pflash0-format","read-only":true,"driver":"raw","file":"libvirt-pflash0-storage"}' \
-blockdev '{"driver":"file","filename":"/var/lib/libvirt/qemu/nvram/5_Windows_10_Enterprise_LTSC_2021_VARS.fd","node-name":"libvirt-pflash1-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-pflash1-format","read-only":false,"driver":"raw","file":"libvirt-pflash1-storage"}' \
-machine pc-i440fx-5.2,accel=kvm,usb=off,dump-guest-core=off,pflash0=libvirt-pflash0-format,pflash1=libvirt-pflash1-format,memory-backend=pc.ram \
-cpu qemu64 \
-m 4096 \
-object memory-backend-ram,id=pc.ram,size=4294967296 \
-overcommit mem-lock=off \
-smp 16,sockets=2,dies=1,cores=4,threads=2 \
-uuid ae88a148-3f3a-40b3-b51b-4058d086d65f \
-no-user-config \
-nodefaults \
-chardev socket,id=charmonitor,fd=34,server,nowait \
-mon chardev=charmonitor,id=monitor,mode=control \
-rtc base=localtime \
-no-shutdown \
-boot strict=on \
-device nec-usb-xhci,id=usb,bus=pci.0,addr=0x4 \
-device ahci,id=sata0,bus=pci.0,addr=0x5 \
-device virtio-serial-pci,id=virtio-serial0,bus=pci.0,addr=0x6 \
-blockdev '{"driver":"file","filename":"/mnt/Eden/Applications/ISOs/19044.1288.211006-0501.21h2_release_svc_refresh_CLIENT_LTSC_EVAL_x64FRE_en-us.iso","node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-2-format","read-only":true,"driver":"raw","file":"libvirt-2-storage"}' \
-device ide-cd,bus=sata0.0,drive=libvirt-2-format,id=sata0-0-0,bootindex=1 \
-blockdev '{"driver":"host_device","filename":"/dev/zvol/Pollen/vms/Windows_10_Enterprise_LTSC_2021-jfc398","aio":"threads","node-name":"libvirt-1-storage","cache":{"direct":true,"no-flush":false},"auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-1-format","read-only":false,"cache":{"direct":true,"no-flush":false},"driver":"raw","file":"libvirt-1-storage"}' \
-device ide-hd,bus=sata0.1,drive=libvirt-1-format,id=sata0-0-1,bootindex=2,write-cache=on \
-netdev tap,fd=37,id=hostnet0 \
-device e1000,netdev=hostnet0,id=net0,mac=00:a0:98:4c:0c:db,bus=pci.0,addr=0x3 \
-chardev pty,id=charserial0 \
-device isa-serial,chardev=charserial0,id=serial0 \
-chardev socket,id=charchannel0,fd=38,server,nowait \
-device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=org.qemu.guest_agent.0 \
-device usb-tablet,id=input0,bus=usb.0,port=1 \
-vnc 10.0.10.13:0 \
-device qxl-vga,id=video0,ram_size=67108864,vram_size=67108864,vram64_size_mb=0,vgamem_mb=16,max_outputs=1,xres=1600,yres=900,bus=pci.0,addr=0x2 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x7 \
-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \
-msg timestamp=on
char device redirected to /dev/pts/6 (label charserial0)
2023-09-07T22:56:51.374104Z qemu-system-x86_64: terminating on signal 15 from pid 3328220 (/usr/sbin/libvirtd)
2023-09-07 22:56:52.374+0000: shutting down, reason=destroyed
2023-09-07 22:59:29.791+0000: starting up libvirt version: 7.0.0, package: 3 (Andrea Bolognani <eof@kiyuko.org> Fri, 26 Feb 2021 16:46:34 +0100), qemu version: 5.2.0Debian 1:5.2+dfsg-11+deb11u2, kernel: 5.15.107+truenas, hostname: TrueNAS.local
LC_ALL=C \
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \
HOME=/var/lib/libvirt/qemu/domain-4-5_Windows_10_Enterpr \
XDG_DATA_HOME=/var/lib/libvirt/qemu/domain-4-5_Windows_10_Enterpr/.local/share \
XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain-4-5_Windows_10_Enterpr/.cache \
XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain-4-5_Windows_10_Enterpr/.config \
QEMU_AUDIO_DRV=none \
/usr/bin/qemu-system-x86_64 \
-name guest=5_Windows_10_Enterprise_LTSC_2021,debug-threads=on \
-S \
-object secret,id=masterKey0,format=raw,file=/var/lib/libvirt/qemu/domain-4-5_Windows_10_Enterpr/master-key.aes \
-blockdev '{"driver":"file","filename":"/usr/share/OVMF/OVMF_CODE.fd","node-name":"libvirt-pflash0-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-pflash0-format","read-only":true,"driver":"raw","file":"libvirt-pflash0-storage"}' \
-blockdev '{"driver":"file","filename":"/var/lib/libvirt/qemu/nvram/5_Windows_10_Enterprise_LTSC_2021_VARS.fd","node-name":"libvirt-pflash1-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-pflash1-format","read-only":false,"driver":"raw","file":"libvirt-pflash1-storage"}' \
-machine pc-i440fx-5.2,accel=kvm,usb=off,dump-guest-core=off,pflash0=libvirt-pflash0-format,pflash1=libvirt-pflash1-format,memory-backend=pc.ram \
-cpu qemu64 \
-m 4096 \
-object memory-backend-ram,id=pc.ram,size=4294967296 \
-overcommit mem-lock=off \
-smp 16,sockets=2,dies=1,cores=4,threads=2 \
-uuid ae88a148-3f3a-40b3-b51b-4058d086d65f \
-no-user-config \
-nodefaults \
-chardev socket,id=charmonitor,fd=34,server,nowait \
-mon chardev=charmonitor,id=monitor,mode=control \
-rtc base=localtime \
-no-shutdown \
-boot strict=on \
-device nec-usb-xhci,id=usb,bus=pci.0,addr=0x4 \
-device ahci,id=sata0,bus=pci.0,addr=0x5 \
-device virtio-serial-pci,id=virtio-serial0,bus=pci.0,addr=0x6 \
-blockdev '{"driver":"host_device","filename":"/dev/zvol/Pollen/vms/Windows_10_Enterprise_LTSC_2021-jfc398","aio":"threads","node-name":"libvirt-1-storage","cache":{"direct":true,"no-flush":false},"auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-1-format","read-only":false,"cache":{"direct":true,"no-flush":false},"driver":"raw","file":"libvirt-1-storage"}' \
-device ide-hd,bus=sata0.0,drive=libvirt-1-format,id=sata0-0-0,bootindex=1,write-cache=on \
-netdev tap,fd=37,id=hostnet0 \
-device e1000,netdev=hostnet0,id=net0,mac=00:a0:98:4c:0c:db,bus=pci.0,addr=0x3 \
-chardev pty,id=charserial0 \
-device isa-serial,chardev=charserial0,id=serial0 \
-chardev socket,id=charchannel0,fd=38,server,nowait \
-device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=org.qemu.guest_agent.0 \
-device usb-tablet,id=input0,bus=usb.0,port=1 \
-vnc 10.0.10.13:0 \
-device qxl-vga,id=video0,ram_size=67108864,vram_size=67108864,vram64_size_mb=0,vgamem_mb=16,max_outputs=1,xres=1600,yres=900,bus=pci.0,addr=0x2 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x7 \
-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \
-msg timestamp=on
char device redirected to /dev/pts/6 (label charserial0)
2023-09-08T00:10:08.492436Z qemu-system-x86_64: terminating on signal 15 from pid 3328220 (/usr/sbin/libvirtd)
2023-09-08 00:10:10.018+0000: shutting down, reason=shutdown
2023-09-08 01:22:30.704+0000: starting up libvirt version: 7.0.0, package: 3 (Andrea Bolognani <eof@kiyuko.org> Fri, 26 Feb 2021 16:46:34 +0100), qemu version: 5.2.0Debian 1:5.2+dfsg-11+deb11u2, kernel: 5.15.107+truenas, hostname: TrueNAS.local
LC_ALL=C \
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \
HOME=/var/lib/libvirt/qemu/domain-5-5_Windows_10_Enterpr \
XDG_DATA_HOME=/var/lib/libvirt/qemu/domain-5-5_Windows_10_Enterpr/.local/share \
XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain-5-5_Windows_10_Enterpr/.cache \
XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain-5-5_Windows_10_Enterpr/.config \
QEMU_AUDIO_DRV=none \
/usr/bin/qemu-system-x86_64 \
-name guest=5_Windows_10_Enterprise_LTSC_2021,debug-threads=on \
-S \
-object secret,id=masterKey0,format=raw,file=/var/lib/libvirt/qemu/domain-5-5_Windows_10_Enterpr/master-key.aes \
-blockdev '{"driver":"file","filename":"/usr/share/OVMF/OVMF_CODE.fd","node-name":"libvirt-pflash0-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-pflash0-format","read-only":true,"driver":"raw","file":"libvirt-pflash0-storage"}' \
-blockdev '{"driver":"file","filename":"/var/lib/libvirt/qemu/nvram/5_Windows_10_Enterprise_LTSC_2021_VARS.fd","node-name":"libvirt-pflash1-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-pflash1-format","read-only":false,"driver":"raw","file":"libvirt-pflash1-storage"}' \
-machine pc-i440fx-5.2,accel=kvm,usb=off,dump-guest-core=off,pflash0=libvirt-pflash0-format,pflash1=libvirt-pflash1-format,memory-backend=pc.ram \
-cpu qemu64 \
-m 4096 \
-object memory-backend-ram,id=pc.ram,size=4294967296 \
-overcommit mem-lock=off \
-smp 16,sockets=2,dies=1,cores=4,threads=2 \
-uuid ae88a148-3f3a-40b3-b51b-4058d086d65f \
-no-user-config \
-nodefaults \
-chardev socket,id=charmonitor,fd=34,server,nowait \
-mon chardev=charmonitor,id=monitor,mode=control \
-rtc base=localtime \
-no-shutdown \
-boot strict=on \
-device nec-usb-xhci,id=usb,bus=pci.0,addr=0x4 \
-device ahci,id=sata0,bus=pci.0,addr=0x5 \
-device virtio-serial-pci,id=virtio-serial0,bus=pci.0,addr=0x6 \
-blockdev '{"driver":"host_device","filename":"/dev/zvol/Pollen/vms/Windows_10_Enterprise_LTSC_2021-jfc398","aio":"threads","node-name":"libvirt-1-storage","cache":{"direct":true,"no-flush":false},"auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-1-format","read-only":false,"cache":{"direct":true,"no-flush":false},"driver":"raw","file":"libvirt-1-storage"}' \
-device ide-hd,bus=sata0.0,drive=libvirt-1-format,id=sata0-0-0,bootindex=1,write-cache=on \
-netdev tap,fd=37,id=hostnet0 \
-device e1000,netdev=hostnet0,id=net0,mac=00:a0:98:4c:0c:db,bus=pci.0,addr=0x3 \
-chardev pty,id=charserial0 \
-device isa-serial,chardev=charserial0,id=serial0 \
-chardev socket,id=charchannel0,fd=38,server,nowait \
-device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=org.qemu.guest_agent.0 \
-device usb-tablet,id=input0,bus=usb.0,port=1 \
-vnc 10.0.10.13:0 \
-device qxl-vga,id=video0,ram_size=67108864,vram_size=67108864,vram64_size_mb=0,vgamem_mb=16,max_outputs=1,xres=1600,yres=900,bus=pci.0,addr=0x2 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x7 \
-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \
-msg timestamp=on
char device redirected to /dev/pts/6 (label charserial0)
2023-09-08T02:36:11.407120Z qemu-system-x86_64: terminating on signal 15 from pid 3328220 (/usr/sbin/libvirtd)
2023-09-08 02:36:12.538+0000: shutting down, reason=shutdown
2023-09-08 03:38:15.966+0000: starting up libvirt version: 7.0.0, package: 3 (Andrea Bolognani <eof@kiyuko.org> Fri, 26 Feb 2021 16:46:34 +0100), qemu version: 5.2.0Debian 1:5.2+dfsg-11+deb11u2, kernel: 5.15.107+truenas, hostname: TrueNAS.local
LC_ALL=C \
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \
HOME=/var/lib/libvirt/qemu/domain-6-5_Windows_10_Enterpr \
XDG_DATA_HOME=/var/lib/libvirt/qemu/domain-6-5_Windows_10_Enterpr/.local/share \
XDG_CACHE_HOME=/var/lib/libvirt/qemu/domain-6-5_Windows_10_Enterpr/.cache \
XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain-6-5_Windows_10_Enterpr/.config \
QEMU_AUDIO_DRV=none \
/usr/bin/qemu-system-x86_64 \
-name guest=5_Windows_10_Enterprise_LTSC_2021,debug-threads=on \
-S \
-object secret,id=masterKey0,format=raw,file=/var/lib/libvirt/qemu/domain-6-5_Windows_10_Enterpr/master-key.aes \
-blockdev '{"driver":"file","filename":"/usr/share/OVMF/OVMF_CODE.fd","node-name":"libvirt-pflash0-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-pflash0-format","read-only":true,"driver":"raw","file":"libvirt-pflash0-storage"}' \
-blockdev '{"driver":"file","filename":"/var/lib/libvirt/qemu/nvram/5_Windows_10_Enterprise_LTSC_2021_VARS.fd","node-name":"libvirt-pflash1-storage","auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-pflash1-format","read-only":false,"driver":"raw","file":"libvirt-pflash1-storage"}' \
-machine pc-i440fx-5.2,accel=kvm,usb=off,dump-guest-core=off,pflash0=libvirt-pflash0-format,pflash1=libvirt-pflash1-format,memory-backend=pc.ram \
-cpu qemu64 \
-m 4096 \
-object memory-backend-ram,id=pc.ram,size=4294967296 \
-overcommit mem-lock=off \
-smp 16,sockets=2,dies=1,cores=4,threads=2 \
-uuid ae88a148-3f3a-40b3-b51b-4058d086d65f \
-no-user-config \
-nodefaults \
-chardev socket,id=charmonitor,fd=34,server,nowait \
-mon chardev=charmonitor,id=monitor,mode=control \
-rtc base=localtime \
-no-shutdown \
-boot strict=on \
-device nec-usb-xhci,id=usb,bus=pci.0,addr=0x4 \
-device ahci,id=sata0,bus=pci.0,addr=0x5 \
-device virtio-serial-pci,id=virtio-serial0,bus=pci.0,addr=0x6 \
-blockdev '{"driver":"host_device","filename":"/dev/zvol/Pollen/vms/Windows_10_Enterprise_LTSC_2021-jfc398","aio":"threads","node-name":"libvirt-1-storage","cache":{"direct":true,"no-flush":false},"auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-1-format","read-only":false,"cache":{"direct":true,"no-flush":false},"driver":"raw","file":"libvirt-1-storage"}' \
-device ide-hd,bus=sata0.0,drive=libvirt-1-format,id=sata0-0-0,bootindex=1,write-cache=on \
-netdev tap,fd=37,id=hostnet0 \
-device e1000,netdev=hostnet0,id=net0,mac=00:a0:98:4c:0c:db,bus=pci.0,addr=0x3 \
-chardev pty,id=charserial0 \
-device isa-serial,chardev=charserial0,id=serial0 \
-chardev socket,id=charchannel0,fd=38,server,nowait \
-device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=org.qemu.guest_agent.0 \
-device usb-tablet,id=input0,bus=usb.0,port=1 \
-vnc 10.0.10.13:0 \
-device qxl-vga,id=video0,ram_size=67108864,vram_size=67108864,vram64_size_mb=0,vgamem_mb=16,max_outputs=1,xres=1600,yres=900,bus=pci.0,addr=0x2 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x7 \
-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \
-msg timestamp=on
char device redirected to /dev/pts/6 (label charserial0)
2023-09-08T04:52:33.475494Z qemu-system-x86_64: terminating on signal 15 from pid 3328220 (/usr/sbin/libvirtd)
2023-09-08 04:52:34.674+0000: shutting down, reason=shutdown

Thank you for helping out!
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
How many cores and threads does your hardware actually have? You should not overprovision CPU threads. Do you really need 16 threads for Windows? The numbers you provide multiply, you specified 2 virtual CPUs with 4 cores each with 2 threads each.

Try 4 CPUs, 1 core, 1 thread or similar.
 

Whattteva

Wizard
Joined
Mar 5, 2013
Messages
1,824

CheeryFlame

Contributor
Joined
Nov 21, 2022
Messages
184
How many cores and threads does your hardware actually have? You should not overprovision CPU threads. Do you really need 16 threads for Windows? The numbers you provide multiply, you specified 2 virtual CPUs with 4 cores each with 2 threads each.

Try 4 CPUs, 1 core, 1 thread or similar.
I tried with 2 CPUs, 1 core and 1 thread and it's still shutting down after around an hour. I believe this VM doesn't need a lot of resources.
 

CheeryFlame

Contributor
Joined
Nov 21, 2022
Messages
184
It may be helpful to check the event logs for shutdown event.

As @Patrick M. Hausen it's not good to over-provision a VM and often may even lead to slow performance issues.
I think, the rule of thumb is to start off with 2 threads and work your way up from there if you need more.

Also, what is the overall use of the RAM? Are there any other VM's besides that Windows VM?
Thank you, I could finally solve it! I'm trying a VM for the first time so I downloaded the evaluation version of Windows LTSC and the reason in the log is the following: "The license period for this installation of Windows has expired. The operating system is shutting down."

Since it's working, time to get my license now!

Thanks for helping out.
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
1694452869237.jpeg

Glad it's working now. :smile:
 
Top