Articles in this section

How to restore SolusVM 2 VPS from backup manually

Applicable to:

  • SolusVM 2

Question

How to restore SolusVM 2 VPS from backup manually

Answer

In order to restore a VPS from backup manually perform the following steps:
1. Create a VPS in SolusVM 2 with the same resources as the backed up one and note its UUID(Hypervisor ID)
2. Stop VPS
3. Connect to Compute Resource over SSH where the created VPS is running
4. Find its LVM image path:

virsh domblklist UUID | grep sda | awk {'print $2'}

5. Fill the LVM image with zeros:

dd if=/dev/zero | dd of=/path/to/lvm bs=1024k

6. Download the VPS backup to the CR

NOTE: It should be a compressed VPS image sda.qcow2.zst or sda.raw.zst


7. If the file is a qcow2.zst image- decompress the image, convert into raw format and copy into the created VPS lvm image from step 4:

unzstd sda.qcow2.zst
qemu-img convert -O raw sda.qcow2 sda.raw
dd if=sda.raw of=/path/to/lvm bs=512k

- If the file is a raw image backup just decompress it and copy into VPS LVM image from step 4:

unzstd sda.raw.zst
dd if=sda.raw of=/path/to/lvm bs=512k

8. Start VPS 

Was this article helpful?

Comments

0 comments

Please sign in to leave a comment.