From e222e78013f2f0b518971bb9a3b18cd71391c3f3 Mon Sep 17 00:00:00 2001 From: "CanbiZ (MickLesk)" <47820557+MickLesk@users.noreply.github.com> Date: Mon, 21 Sep 2026 12:37:36 +0200 Subject: [PATCH] truenas-vm: strip the G before the storage allocation storage:N wants a plain number; vm_prompt_disk_size returns 32G, so the advanced path failed with "unable to parse zfs volume name '32G'". --- vm/truenas-vm.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vm/truenas-vm.sh b/vm/truenas-vm.sh index 1bb377815..984a94ac1 100644 --- a/vm/truenas-vm.sh +++ b/vm/truenas-vm.sh @@ -81,7 +81,7 @@ function default_settings() { VMID=$(get_valid_nextid) ISO_DEFAULT="latest stable" vm_apply_machine_type "q35" - DISK_SIZE="16" + DISK_SIZE="16G" DISK_CACHE="" HN="truenas" CPU_TYPE=" -cpu host" @@ -161,7 +161,7 @@ msg_info "Creating TrueNAS VM shell" qm create "$VMID"${MACHINE} -bios ovmf -agent enabled=1 -tablet 0 -localtime 1${CPU_TYPE} \ -cores "$CORE_COUNT" -memory "$RAM_SIZE" -balloon 0 -name "$HN" -tags community-script \ -net0 "virtio,bridge=$BRG,macaddr=$MAC$VLAN$MTU" -onboot 1 -ostype l26 \ - -efidisk0 $STORAGE:1,efitype=4m,pre-enrolled-keys=0 -sata0 $STORAGE:$DISK_SIZE,ssd=1 \ + -efidisk0 $STORAGE:1,efitype=4m,pre-enrolled-keys=0 -sata0 ${STORAGE}:${DISK_SIZE%G},ssd=1 \ -scsihw virtio-scsi-single -cdrom local:iso/$ISO_NAME -boot order='sata0;ide2' -vga virtio >/dev/null msg_ok "Created VM shell"