[virt-tools-list] Creating XML using template XML file
Cole Robinson
crobinso at redhat.com
Thu Oct 1 14:35:48 UTC 2009
On 10/01/2009 08:17 AM, Daniel Huhardeaux wrote:
> Hi,
>
> I installed few VM's based on a file template installation with dd. I
> also have an xml for this template VM. Is there a way in virsh to import
> the template VM XML file, adapt it to new VMs need and save it as new
> domain?
>
> What I do at this time:
>
> #cd /etc/libvirtd/qemu
> #cp VmTemplate.xml NewDomain.xml
> # vi NewDomain.xml, adapt the few parameters I have to modify and save
> # virsh --connect qemu:///system create NewDomain.xml
> # virsh --connect qemu:///system autostart NewDomain.xml
>
You need to use 'virsh define <xmlfile>'. This will add the domain to
the persistent VM list. 'virsh create' makes a transient VM that will
disappear once it is shutdown.
- Cole
More information about the virt-tools-list
mailing list