Dump/Backup for running containers on btrfs not working with mode=snapshot (umount: /mnt/vzsnap0/: not mounted)

patrickh

New Member
Feb 12, 2024
1
0
1
As the title says, I get errors when trying to backup LXC containers whose volumes are on btrfs storage. This happens on multiple proxmox instances, even on freshly installed without anything configured/changed.

Storage config:
Code:
btrfs: local-btrfs
    path /var/lib/pve/local-btrfs
    content iso,vztmpl,backup,images,rootdir

Container config (also happens without mp0):
Code:
arch: amd64
features: keyctl=1,mknod=1,nesting=1
hostname: s01.lan
memory: 2048
mp0: local-btrfs:100/subvol-100-disk-1.subvol,mp=/volumes,backup=1,size=1
net0: name=eth0,bridge=vmbr0,hwaddr=BC:24:11:60:2D:28,ip=dhcp,ip6=dhcp,type=veth
onboot: 1
ostype: debian
parent: vzdump
rootfs: local-btrfs:100/subvol-100-disk-0.subvol,size=0T
swap: 512
timezone: host
unprivileged: 1

vzdump Log:
Code:
root@pve01:~# vzdump --compress zstd --mode snapshot --storage local-btrfs 100
INFO: starting new backup job: vzdump 100 --storage local-btrfs --mode snapshot --compress zstd
INFO: filesystem type on dumpdir is '-' -using /var/tmp/vzdumptmp1018801_100 for temporary files
INFO: Starting Backup of VM 100 (lxc)
INFO: Backup started at 2024-02-12 13:48:56
INFO: status = running
INFO: CT Name: s01.lan
INFO: including mount point rootfs ('/') in backup
INFO: including mount point mp0 ('/volumes') in backup
INFO: found old vzdump snapshot (force removal)
INFO: backup mode: snapshot
INFO: ionice priority: 7
INFO: suspend vm to make snapshot
INFO: create storage snapshot 'vzdump'
umount: /mnt/vzsnap0/: not mounted.
command 'umount -l -d /mnt/vzsnap0/' failed: exit code 32
INFO: resume vm
INFO: guest is online again after 1 seconds
ERROR: Backup of VM 100 failed - cannot mount subvol snapshots for storage type 'btrfs'
INFO: Failed at 2024-02-12 13:48:57
INFO: Backup job finished with errors
INFO: notified via target `mail-to-root`
job errors

Using mode=snapshot, mode=stop works always and mode=snapshot only works with a stopped container.

Is there some configuration I have to change or is this a bug/missing implementation in the btrfs storage implementation?
 
Last edited:

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!