SolusVM :: Migration KVM Virtualization to Another Node

47 sec read

:: What’s KVM
KVM (Kernel-based Virtual Machine) is a full virtualization for Linux.

 
:: How to Migrate guest KVM VPS in SolusVM
+ Preparing in old node server
0. Shutdown KVM VPS

virsh list
virsh shutdown kvm103

or you can click Shutdown via SolusVM Master

1. Check LV Path for KVM VPS

 lvdisplay 

you will see some like these:

  --- Logical volume ---
  LV Path                /dev/vg/kvm103_img
  LV Name                kvm103_img
  VG Name                vg
  LV UUID                YMZRmv-Bvh0-HbUz-2Jei-QTkv-ynhe-eAhlO7
  LV Write Access        read/write
  LV Creation host, time kvm.blackonsole.org, 2013-01-21 18:12:46 -0600
  LV Status              available
  # open                 1
  LV Size                60.00 GiB
  Current LE             1920
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     4096
  Block device           253:0

2. Create image from the lv path

 dd if=/dev/vg/kvm103_img | gzip | dd of=kvm103.gz bs=4096

3. Transfer image to new server

 rsync kvm103.gz root@newserver:~

 
+ In New Server
0. Create new lv in lvm group

lvcreate -n kvm103_img --size 60G /dev/vg01

1. Restore image in new server

dd if=kvm103.gz | gzip -d | dd of=/dev/vg01/kvm103_img bs=4096

 
+ in SolusVM Master
0. Change Node ID for KVM VPS

/script/vm-migrate VSERVERID NEWNODEID

example:

/script/vm-migrate 10 4

1. Start / Click Boot for reboot KVM VPS in new node

 
:: links
+ Google
+ SolusVM

Reset root password on CentOS 7

Edit boot menu on-the-go 0. reboot the CentOS 7 and press ESC when GRUB menu show up on the screen and press “e”1. find...
Sysadmin.ID
18 sec read

Leave a Reply

Your email address will not be published. Required fields are marked *