[libvirt-users] [libvirt] How to rename a domain?

Cole Robinson crobinso at redhat.com
Thu Oct 14 15:12:18 UTC 2010


On 10/12/2010 12:58 PM, Ganesh Pagade wrote:
> Hi,
> 
> I am using libvirt Java bindings. How can I rename a domain? Is there an API
> to do this?
> 

There is no API for it. The only way to do it is basically:

virsh dumpxml myvm > foo.xml
<edit foo.xml, change the name>
virsh undefine myvm
virsh define foo.xml

- Cole




More information about the libvirt-users mailing list