Step for cloning xen dumU disk p_w_picpath within the SAME xen host

Summary :

1. Get the vm guest for the xm list

2. Shut down the vm guest

3. Use the virt-clone interactively by providing needed information

4. Change any information such as fixed IP address under new configuration file under /etc/xen

/* Here are the steps */

[root@xen /etc]# xm list
Name                                      ID Mem(MiB) VCPUs State   Time(s)
Domain-0                                   0     3272     2 r—–   3109.5
vm01                                       5      511     1 -b—-     18.2
[root@xen /etc]# xm shutdown vm01
[root@xen /etc]# virt-clone –prompt
What is the name of the original virtual machine? vm01
What is the name for the cloned virtual machine? vm02
What would you like to use as the cloned disk (file path) for ‘/var/lib/xen/p_w_picpaths/vm01.img’? /var/lib/xen/p_w_picpaths/vm02.img
Cloning /var/lib/xen/p_w_picpaths/vm01.img                     | 7.8 GB     02:08

Clone ‘vm02′ created successfully.

Step for cloning xen dumU disk p_w_picpath to REMOTE xen host

1. Copy both config and disk p_w_picpath to remote machine, i.e.,

scp -p /etc/xen/vm03 192,168,1.38:/etc/xen

rsync -avr /var/lib/xen/p_w_picpaths/vm03.img

2.  Check the config file to see if any information needed to change


After the files copied to the remote xen host, the new vm guest will be shown automatically under the Virtual Machine Manager.