Articles in this section

How to move manually VMs from one storage to another in SolusVM 2?

Applicable to:

  • SolusVM 2

Question

How to move manually VMs from one storage to another in SolusVM 2?

Answer

  1. Create a partition on/dev/sdb
  2. Mount new partition to a new empty directory where you want to store VMs' data
  3. Add new storage in SolusVM 2 UI pointing to a directory you've used in step 2.
  4. Switch off a VM to stop it from running read/write operations with current disk
  5. Check the VM's image path:

    # virsh domblklist UUID

    Note: The UUID is taken form the admin panel when you open the VPS settings under its name. 

  6. For Example:

    # virsh domblklist bdfcdc75-4c3c-44ab-bddb-4fa71b503732 
    Target   Source 
    ----------------------------------------------------- 
    sda      /var/lib/libvirt/images/94/0 
    sdz      /usr/local/solus/iso_images/94/config.iso 
     

  7. Move image file to a directory from step 2 (/var/lib/libvirt/images/94/0 is the image here)
  8. Edit VM's configuration file:

    # virsh edit UUID 

  9. Find the string with current path /var/lib/libvirt/images/94/0 and change it to a new one.
  10. Start the VM.

Repeat steps 4-9 for the rest of VMs.

Was this article helpful?

Comments

0 comments

Please sign in to leave a comment.