Xen and DomU Clone
June 27, 2009
This basic approach works:
-
Power down target system.
-
Create another logical volume the same size as the target system.
-
dd if=/dev/$PV/$TARGET of=/dev/$PV/$CLONE bs=1M
-
Copy Xen config and modify with clone details
-
Power up clone, change hostname and any other relevant details
-
Power up target
For a 32 GB LV, dd took just over 11 minutes to dump the data from the target volume to the clone volume on my hardware. This was for a Windows Server 2003 clone using DHCP so the only thing I changed was the host name (so far).
I’d think the LVM snapshot method might be able to do this more intelligently but I couldn’t quite grok it right away and this method worked.
Categories:
Xen
Tags:
virtualization
Xen