add xml-dump of vm to backup
This commit is contained in:
parent
a538042eba
commit
fdb28a42a9
@ -45,6 +45,9 @@ done
|
|||||||
# create snapshot dataset
|
# create snapshot dataset
|
||||||
zfs create tank/snapshots/$VM
|
zfs create tank/snapshots/$VM
|
||||||
|
|
||||||
|
# create virsh xml-dump of vm
|
||||||
|
virsh dumpxml $VM > /srv/vms/$VM/vm-$VM.xml
|
||||||
|
|
||||||
virsh snapshot-create-as --domain $VM --name $SNAPNAME --quiesce --atomic --disk-only $DISKSPEC >/dev/null 2>&1
|
virsh snapshot-create-as --domain $VM --name $SNAPNAME --quiesce --atomic --disk-only $DISKSPEC >/dev/null 2>&1
|
||||||
if [ $? -ne 0 ]
|
if [ $? -ne 0 ]
|
||||||
then
|
then
|
||||||
|
Loading…
Reference in New Issue
Block a user