Applicable to:
- SolusVM 2
Question
How to move VPS from one storage to another within one CR?
Answer
- Note the VPS
UUIDand Stop the VPS in SolusVM 2 -
Create a logical volume of the same disk space on the second storage:
# lvcreate -L 10G -n 1 /dev/storage2
-
Copy the original VPS LVM image into the created one:
# dd if=/dev/storage1/1 | dd of=/dev/storage2/1 bs=8192
-
Open the VPS config for editing using UUID from step 1:
# virsh edit UUID
-
Find the line with the VPS LVM image:
CONFIG_TEXT: source file='/dev/storage1/1'/>
and change the source file path to the new one:
<source file='/dev/storage2/1'/> - Connect to SolusVM 2 management node via SSH
- Create the database backup:
How-to-create-SolusVM-2-database-backup - Connect to database:
How-to-access-SolusVM-2-database -
Update the storage ID for the VPS:
# update compute_resource_vms set storage_id=NEW_STORAGE_ID where id=VPS_ID;
Replace"NEW_STORAGE_ID"and"VPS_ID"correspondingly.
Comments
Please sign in to leave a comment.