[libvirt] Windows VM doesn't start as Linux one does

Daniel Huhardeaux tech at tootai.net
Wed Nov 11 17:56:37 UTC 2009


everything is in the subject. I'm running Debian SID with libvirt-bin 
0.7.2-3 and virt-manager 0.8.0-2.

I had 4 VMs created manually some times ago (Lenny, Ubuntu 9.04, W2k and 
XPHome) which I migrate to libvirt. Both Linux are booting well, both 
Windows not: they start but suddenly reboot.

On W2K I see the white starting bannier increasing on the bottom off the 
screen, and when done, reboot.
On XPh at the time where the booting Windows screen should appear, VM 
restart. The I get the famous "Windows hasn't shutdown clearly, do you 
want to start in safe mode ... aso)

On both systems, after first fail reboot, I can try and try again, 
always the same. If I stared VMs manually, no problem!

My start script -which started without any problem my XPHome VM- is:



sudo /usr/bin/kvm -localtime -cdrom /dev/scd0 -boot c -hda 
/media/XP/vdisk.img -hdb /media/XP/vdisk1.img -m 512 -soundhw $AUDIO 
-vga $VGA\
       -net nic,vlan=0 -net vde,vlan=0,sock=/var/run/vde.ctl -usb -smb 
public -monitor tcp:,server,nowait &

The XML file for the same VM which fail on boot is:

<domain type='kvm'>                              
    <type arch='x86_64' machine='pc'>hvm</type>   
    <boot dev='hd'/>                              
  <clock offset='localtime'/>
    <disk type='file' device='disk'>
      <source file='/media/XP/vdisk.img'/>
      <target dev='hda' bus='ide'/>
    <disk type='file' device='disk'>
      <source file='/media/XP/vdisk1.img'/>
      <target dev='hdb' bus='ide'/>
    <disk type='block' device='cdrom'>
      <source dev='/dev/cdrom'/>
      <target dev='hdc' bus='ide'/>
    <interface type='bridge'>
      <mac address='54:52:00:7a:ee:01'/>
      <source bridge='virbr2'/>
    <serial type='pty'>
      <source path='/dev/pts/6'/>
      <target port='0'/>
    <console type='pty' tty='/dev/pts/6'>
      <source path='/dev/pts/6'/>
      <target port='0'/>
    <input type='tablet' bus='usb'/>
    <input type='mouse' bus='ps2'/>
    <graphics type='vnc' port='-1' autoport='yes' keymap='en-us'/>
    <sound model='es1370'/>
      <model type='cirrus' vram='9216' heads='1'/>

~>qemu-img info /media/XP/vdisk.img
image: /media/XP/vdisk.img
file format: raw
virtual size: 6.0G (6442450944 bytes)
disk size: 5.8G

~>qemu-img info /media/XP/vdisk1.img
image: /media/XP/vdisk1.img
file format: raw
virtual size: 2.0G (2147483648 bytes)
disk size: 268M

The disk image from all Linux VMs are also raw.

On another server I installed from scratch on LVM partition an XPPro 
Windows VM without any problem.

Thanks for any hint.



More information about the libvir-list mailing list