[et-mgmt-tools] Idea/help with virt-clone?

Michael DeHaan mdehaan at redhat.com
Mon Jul 14 18:25:07 UTC 2008


Here's something I would like to see, but do not know how to cleanly 
accomplish:

virt-clone -o GUESTNAME -f NEWDISKFILE -x NEWXML

The idea here is I really want to be able to clone guests, but I don't 
necessarily want to clone them on the same host.  Instead, I want to be 
able to track a central library of guests (and their associated disk 
images) in cobbler that I can clone later -- in my case, koan will be 
just doing the bare-minimum to get the virt-image parameters right to 
feed to virt-image.  So, in order to do this, I also need to get some 
XML out of the guest that is compatible with virt-image, so I can save 
it on the central server.

The problem I have now is that the XML coming out of virsh dumpxml is 
not compatible with virt-image.

This "-x" output would need to be in virt-image format and it would 
write this XML in addition to the diskfile.

For example, once established, I could just feed this back into 
virt-image like so:

virt-image foo.xml --n NEWNAME -u NEWUUID -m NEWMAC -b NEWBRIDGE

I do not think I'm familiar with virtinst internals to add this, though 
it's something we are going to eventually need for ovirt.

You can see a bit of what syntax I'm getting at (and the general idea) here:

https://fedorahosted.org/cobbler/wiki/KoanWithIsos

Though in addition koan would be tracking the xmlfile for cloning info 
as well.

--Michael





More information about the et-mgmt-tools mailing list