diff --git a/lib.sh b/lib.sh index 6bdb929..60ffd36 100755 --- a/lib.sh +++ b/lib.sh @@ -42,7 +42,8 @@ build_template() { fi virt-customize -a "$disk" --truncate /etc/machine-id - qm create "$VM_ID" --name "$VM_NAME" --net0 "virtio,bridge=$BRIDGE" + # cpu host: AlmaLinux 9 needs x86-64-v2 and won't boot on the old kvm64 default + qm create "$VM_ID" --name "$VM_NAME" --cpu host --net0 "virtio,bridge=$BRIDGE" qm set "$VM_ID" --cores "$CPU_CORE" --sockets "$CPU_SOCKET" --memory "$RAM" qm set "$VM_ID" --scsihw virtio-scsi-pci --scsi0 "$STORAGE:0,import-from=$disk,discard=on" qm set "$VM_ID" --ide2 "$STORAGE:cloudinit"