Feature request - use the machine name in the backup label rather than the VMID

yatesco

Renowned Member
Sep 25, 2009
214
5
83
First off - the backup capabilities (and reliability!) of Proxmox is primarily why I have returned from the pretty darn good world of ESXi.

However, one maintenance pain is that the backups contain the VMID which doesn't really mean anything to me.

It would be great if the backups contained the name of the machine as well.
 
However, one maintenance pain is that the backups contain the VMID which doesn't really mean anything to me.
It would be great if the backups contained the name of the machine as well.

I thought the same, and also wanted to have easier access to the vm config in the backup files (without having to extract files from the tgz files.
So i wrote a small patch for that, adding two more options to vzdump (4 files patched), to be able to set the vm name in the backup files, and to have the vm config dumped in the backup log file ...

I sent the fields to PVE team but don't know if they're interested to add those options in the standard release - i guess not. If you want, i could attach them here for you to experiment... i think it's ok for PVE staff.
Please note that I can't mantain those, you are on your own...

here is a sample job i just did, as an example (vm name is apint_kvm)
--------------------------------------------
Code:
#sudo vzdump --dumpdir /mnt/pve/vm_backup/pvetest/ --compress --logwithname --logvmconfig --snapshot 102

INFO: starting new backup job: vzdump --bwlimit 1000000 --dumpdir /mnt/pve/vm_backup/pvetest/ --compress --logwithname --logvmconfig --snapshot 102
INFO: Starting Backup of VM 102 (qemu)
INFO: stopped
INFO: status = stopped
INFO: backup mode: stop
INFO: bandwidth limit: 1000000 KB/s
INFO: creating archive '/mnt/pve/vm_backup/pvetest/vzdump-qemu-102-apint_kvm-2010_07_05-11_51_46.tgz'
INFO: adding '/mnt/pve/vm_backup/pvetest/vzdump-qemu-102-apint_kvm-2010_07_05-11_51_46.tmp/qemu-server.conf' to archive ('qemu-server.conf')
INFO: adding '/var/lib/vz/images/102/vm-102-disk-1.vmdk' to archive ('vm-disk-ide0.vmdk')
INFO: Total bytes written: 3653693440 (6.42 MiB/s)
INFO: archive file size: 2.00GB
INFO: stopped
INFO: vmconfig:
INFO: ========
INFO:  disksize=8
INFO:  ide2=cdrom,media=cdrom
INFO:  name=apint_kvm
INFO:  vlan0=rtl8139=26:86:86:CA:F8:1A
INFO:  bootdisk=ide0
INFO:  ostype=other
INFO:  ide0=local:102/vm-102-disk-1.vmdk
INFO:  disktype=ide
INFO:  memory=512
INFO:  diskinfo:
INFO:    ide0:
INFO:      index=0
INFO:      disksize=8
INFO:      file=local:102/vm-102-disk-1.vmdk
INFO:      interface=ide
INFO:    ide2:
INFO:      index=2
INFO:      disksize=0
INFO:      media=cdrom
INFO:      file=cdrom
INFO:      interface=ide
INFO:  sockets=1
INFO: Finished Backup of VM 102 (00:09:06)
INFO: Backup job finished successfuly
----------------------------------------------------

Marco
 
Last edited: