Commit Graph
4 Commits
Author SHA1 Message Date
dualfroz 5ef4888910 fix #6391: restore: fall back to automatic VM state storage if unavailable
Restoring a backup keeps the 'vmstatestorage' option of the backed up
VM. When the backup is restored on another node or cluster, that
storage might not exist there or not be enabled for the node, so that
hibernating the VM or taking a snapshot including RAM fails later on,
for example with "storage 'local-zfs-pve1' does not exist".

If the configured VM state storage is not available on the node the
backup is restored to, drop the option, so that the storage is
selected automatically, like for VMs without it, and log that in the
restore task log.

A 'vmstatestorage' passed explicitly when restoring is applied after
this and is not affected.

Signed-off-by: Michal Fox <me@dualfroz.com>
2026-10-03 01:40:02 +02:00
upstream b2fcf5405f Upstream proxmox-git/qemu-server state of the touched files before 7e62afd562 2026-10-03 01:40:02 +02:00
dualfroz b8ae251afe fix #7173: write config: drop empty tag list
When the last tag of a VM gets removed, for example in the web UI, the
API gets an empty 'tags' value, which then ends up as an empty 'tags:'
line in the config and in the output of 'qm config'. As the config
parser reads that line back as a single space, it also gets written out
again on every following config change.

Skip a tag list without any tag when writing the config, which also
cleans up existing configs with such a line on their next change. The
pending section still needs to keep it, otherwise the removal of all
tags would get lost between writing the pending change and applying it.

Signed-off-by: Michal Fox <me@dualfroz.com>
2026-10-02 16:11:58 +02:00
upstream 91f98b77f4 Upstream proxmox-git/qemu-server state of the touched files before e84bce8d0f 2026-10-02 16:11:58 +02:00