Re: [Sheepdog][Libvirt]Boot VMs from sheepdog volumes error

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 02/01/2013 04:08 AM, harryxiyou wrote:
> Hi all,
> 
> I wanna boot VMs from sheepdog volumes so i do according to
> https://github.com/collie/sheepdog/wiki/Libvirt
> However, some errors happened to me like following.
> 
> $ ./virsh create os.xml
> error:create domain from os.xml failure
> error:(domain_definition):14: Premature end of data in tag domain line 1
> (null)
> ^

That says your <domain> tag is incomplete.  Sure enough...

> 
> $ cat os.xml
> <domain type='qemu'>

You opened it...

> <name>testvm</name>
> <memory>1048576</memory>
> <os>
> <type arch='x86_64'>hvm</type>
> </os>
> <devices>
> <disk type='network'>
> <source protocol="sheepdog" name="testvdi"/>
> <target dev='hda' bus='ide'/>
> </disk>
> <graphics type='vnc' port='-1' autoport='yes'/>
> </devices>

...but never closed it with </domain>.

> 
> Could anyone give me some help? Thanks.

Rather than writing XML by hand from scratch, I highly recommend using a
higher level program like virt-manager to create a scratch VM, and then
use 'virsh edit' to hand tune the resulting XML.  That way, you are less
likely to forget something essential, and will at least have the benefit
of seeing how libvirt indents constructs rather than struggling to
visually pick out the indentation with everything starting on the first
column.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]