Installation guide

3.
Mo u n t th e sh ared st o rag e o n t h e d est in at io n
On the destination system, mount the /var/lib/libvirt/images directory:
# mount sourceURL:/var/lib/libvirt/images /var/lib/libvirt/images
Warning
Whichever directory is chosen for the guests must exactly the same on host and guest.
This applies to all types of shared storage. The directory must be the same or the
migration will fail.
22.3. Live KVM migrat ion wit h virsh
A guest can be migrated to another host with the virsh command. The migrate command accepts
parameters in the following format:
# virsh migrate --live GuestName DestinationURL
The GuestName parameter represents the name of the guest which you want to migrate.
The DestinationURL parameter is the URL or hostname of the destination system. The destination
system must run the same version of Red Hat Enterprise Linux, be using the same hypervisor and
have libvirt running.
Once the command is entered you will be prompted for the root password of the destination system.
Examp le: live mig rat io n wit h virsh
This example migrates from test1.example.com to test2.example.com. Change the host
names for your environment. This example migrates a virtual machine named RHEL4test.
This example assumes you have fully configured shared storage and meet all the prerequisites
(listed here: Migration requirements).
1.
Verif y t h e gu est is run n in g
From the source system, test1.example.com, verify RHEL4test is running:
[root@test1 ~]# virsh list
Id Name State
----------------------------------
10 RHEL4 running
2.
Mig rat e t h e gu est
Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e
232