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

Re: [et-mgmt-tools] Can't create new machines using virt-image - missing something obvious, likely user error...



Stephan wrote:
> Hi,
> 
> Thanks to the help from before and documentation all over the place, I'm
> now using libvirt, KVM, virt-install and vmbuilder from Ubuntu, everything
> is going really well (so thanks for that).
> 
> The next thing I've been trying is getting Windows XP virtualised. I have
> managed now and have a virtual machine defined in libvirt, that's all fine.
> 
> So now what I'd like to do is prepare an XML file and a hard drive image
> that I can send on DVD to the other offices at work for them to install
> using virt-image.
>

Cool!

> Here's my XML for virt-image:
> 
> <image>
>   <name>testimage</name>
>   <domain>
>     <boot type="hvm">
>       <guest>
>         <arch>x86_64</arch>
>         <features>
>           <acpi state="off"/>
>         </features>
>       </guest>
>       <os>
>         <loader dev="hd"/>
>       </os>
>       <drive disk="xpvmimage.raw" format="raw"/>
>     </boot>
>     <devices>
>       <vcpu>4</vcpu>
>       <memory>262144</memory>
>       <interface/>
>       <graphics/>
>     </devices>
>   </domain>
>   <storage>
>     <disk file="root.hdd" use="system" format="raw"/>
>   </storage>
> </image>
> 

The problem is with the above xml: it isn't formatted correctly. For
every <drive> entry in the <domain> block, there needs to be a <disk>
entry in the <storage> block.

Check out man 5 virt-image for more detailed info, and an example config.

One feature that would help you in this case is the ability to specify
the OS type and variant (either via the virt-image cli or in the image
format). Otherwise, the VM clock setting will be incorrect for windows
VMs (utc instead of localtime). Unfortunately that feature doesn't exist
yet :(

Hope that helps!
Cole


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