中文 English

ProxmoxVE 6.3 uses commands to back up Synology virtual machines

Published: 2021-01-21
PVE Proxmox VE dsm backup bash sata

Since the Synology virtual machine in my ProxmoxVE runs on a LUN passthrough disk, I cannot click backup directly in the Web interface.

It is really troublesome and error-prone to do this entirely through the Web interface. So I studied the command-line workflow.

Please modify the following values for your environment: VM ID, IP address, SATA number, backup path, and disk ID.

Connect to DSM

ssh root@192.168.xxx.xxx

Close DSM

shutdown -h now

Connect to PVE

ssh root@192.168.xxx.xxx

Unmount the hard drive

Reference: https://pve.proxmox.com/pve-docs/qm.1.html

qm set 1000 -delete sata3
qm set 1000 -delete sata4

Perform backup operation

Reference: https://pve.proxmox.com/wiki/Backup_and_Restore

vzdump 1000 --dumpdir /mnt/pve/dsm20-iso/dump --mode snapshot --compress zstd

Mount hard disk

ls /dev/disk/by-id
qm set 1000 -sata3 /dev/disk/by-id/ata-ST8000DM004-2CX188_ZCT00CDM
qm set 1000 -sata4 /dev/disk/by-id/ata-WDC_WD80EZAZ-11TDBA0_2SG8LSRJ

Start the virtual machine

qm start 1000