Bug 907556
Summary: | windows 8 32bit can not be installed by using libvirt (sep flag is not passed through to the guest) | ||||||
---|---|---|---|---|---|---|---|
Product: | Red Hat Enterprise Linux 6 | Reporter: | Mike Cao <bcao> | ||||
Component: | libvirt | Assignee: | Peter Krempa <pkrempa> | ||||
Status: | CLOSED DUPLICATE | QA Contact: | Virtualization Bugs <virt-bugs> | ||||
Severity: | urgent | Docs Contact: | |||||
Priority: | urgent | ||||||
Version: | 6.4 | CC: | acathrow, areis, bcao, bsarathy, dallan, dawu, dyasny, dyuan, iheim, juzhang, knoel, lcui, lveyde, michen, mkenneth, mzhan, rhod, rwu, sales, shuang, tburke, tzheng, virt-maint, vrozenfe, yongjie.ren, yvugenfi | ||||
Target Milestone: | rc | Keywords: | Reopened, TestBlocker | ||||
Target Release: | --- | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Whiteboard: | |||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | 832301 | Environment: | |||||
Last Closed: | 2013-03-08 09:37:48 UTC | Type: | Bug | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Bug Depends On: | 832301 | ||||||
Bug Blocks: | |||||||
Attachments: |
|
Description
Mike Cao
2013-02-04 17:30:52 UTC
While we are at it, the NX parameter also gets ignored and does not transfer to the command line. Windows 8 requires sse2, nx and sep. I can be an early tester of a fix, once one is made available. Libvirt doesn't add flags to the command line that are already part of the model definition in qemu, thus the sep, nx and others are missing from the command line. This is to make the command line shorter. Qemu should enable them by using the correct model. The error originates from 2 possible sources: 1) qemu does not support that feature for some reason and complains about it. Libvirt is unfortunately not enforcing all the flags and allows the guest to start. This leads to two possible resolutions: 1a) The lack of support of the feature flag is intentional for some reason in qemu and libvirt should fail rather than silently ignore the missing flag. In that case this bug should be closed as a duplicate of https://bugzilla.redhat.com/show_bug.cgi?id=822148 that tracks the issue of enforcing flags globally. 1b) It is a qemu/kernel/other bug that should be fixed as sep is expected to work on the setup used. 2) the sep flag needs to be enforced even if it is part of the cpu model definition in qemu. This would be very unfortunate and it would also be preferably fixed in qemu rather than in libvirt. I'm reassigning this bug to qemu-kvm to investigate further. Alves, could you please attach a relevant part of /var/log/libvirt/qemu/Windows-8 that contains messages printed by qemu on startup? This might help investigating the problem. Created attachment 703097 [details]
This the qemu log as instructed
I started the domain WW8 until it blew up and this is the qemu log
(In reply to comment #6) > Libvirt doesn't add flags to the command line that are already part of the > model definition in qemu, thus the sep, nx and others are missing from the > command line. This is to make the command line shorter. Qemu should enable > them by using the correct model. Actually, the SEP flag is _not_ part of the CPU model definition we have in rhel6.4.0 machine-types and older. This happened because of kernel bug 821463. This problem is combined with other issues: - I believe libvirt doesn't expect the CPU model definitions from QEMU to ever change between machine-types. So removing SEP from cpu_map.xml will probably cause problems when we finally fix bug 821741 (where rhel6.5.0 and newer machine-types will finally have SEP enabled). - The kernel from RHEL 6.3.0 and older can't expose SEP to guests (bug 821463), but libvirt is completely unable to detect that. So even if cpu_map.xml didn't include "sep" on Nehalem, libvirt would try to use "-cpu Nehalem,+sep" and expect it to work. But: - libvirt doesn't use the "enforce" flag, so "-cpu <model>,+sep" wouldn't work on RHEL 6.3.0 and older, but it wouldn't emit any errors or warnings. So, I see two solutions to this: 1) Changing libvirt to handle the fact that QEMU CPU models may be different depending on the machine-type, and take into account that "-M rhel6.4.0 -cpu Nehalem" doesn't have the SEP flag (but "-M rhel6.4.0 -cpu Nehalem,+sep" would work) and that "-M rhel6.5.0 -cpu Nehalem" will probably have it (when we fix bug 821741). 2) Live with the fact that libvirt can't handle CPU models that change between machine-types, and wait until bug 821741 is fixed in QEMU. I will move this bug back to libvirt just in case you want to follow the first approach. If you think the second approach is better, you can close this bug as duplicate of bug 821741. do all models support sep at hardware level (conroe, penryn, nehalem, westemere, etc, and AMD G1-G5)? (In reply to comment #5) > While we are at it, the NX parameter also gets ignored and does not transfer > to the command line. Windows 8 requires sse2, nx and sep. I can be an early > tester of a fix, once one is made available. Please try to modify the XML of the domain: a) add xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0' to the domain tag so it will look like: <domain type='kvm' xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0'> b) add the following tags inside the domain tag: <qemu:commandline> <qemu:arg value='-cpu'/> <qemu:arg value='<YOUR_CPU_MODEL>,+sep'/> </qemu:commandline> so that the final XML will look like i.e.: <domain type='kvm' xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0'> <name>Windows-8</name> <uuid>478a2330-4bf0-d4d5-08ac-82c328df06e9</uuid> <memory unit='KiB'>2097152</memory> <currentMemory unit='KiB'>2097152</currentMemory> <vcpu placement='static'>2</vcpu> <os> <type arch='x86_64' machine='rhel6.4.0'>hvm</type> <boot dev='hd'/> </os> <features> <acpi/> <apic/> <pae/> </features> <cpu mode='custom' match='exact'> <model fallback='allow'>Nehalem</model> <vendor>Intel</vendor> <feature policy='require' name='tm2'/> <feature policy='require' name='est'/> <feature policy='require' name='monitor'/> <feature policy='require' name='ds'/> <feature policy='require' name='ss'/> <feature policy='require' name='vme'/> <feature policy='require' name='dtes64'/> <feature policy='require' name='rdtscp'/> <feature policy='require' name='ht'/> <feature policy='require' name='dca'/> <feature policy='require' name='pbe'/> <feature policy='require' name='tm'/> <feature policy='require' name='pdcm'/> <feature policy='require' name='vmx'/> <feature policy='require' name='ds_cpl'/> <feature policy='require' name='xtpr'/> <feature policy='require' name='acpi'/> <feature policy='require' name='x2apic'/> <feature policy='force' name='sep'/> <feature policy='force' name='nx'/> </cpu> <clock offset='localtime'> <timer name='rtc' tickpolicy='catchup'/> </clock> <on_poweroff>destroy</on_poweroff> <on_reboot>restart</on_reboot> <on_crash>restart</on_crash> <devices> <emulator>/usr/libexec/qemu-kvm</emulator> <disk type='file' device='disk'> <driver name='qemu' type='raw' cache='none'/> <source file='/var/lib/libvirt/images/WIN8.img'/> <target dev='hda' bus='ide'/> <address type='drive' controller='0' bus='0' target='0' unit='0'/> </disk> <controller type='usb' index='0'> <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/> </controller> <controller type='ide' index='0'> <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/> </controller> <interface type='bridge'> <mac address='52:54:00:d1:e4:15'/> <source bridge='br5'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/> </interface> <serial type='pty'> <target port='0'/> </serial> <console type='pty'> <target type='serial' port='0'/> </console> <input type='tablet' bus='usb'/> <input type='mouse' bus='ps2'/> <graphics type='vnc' port='-1' autoport='yes'/> <sound model='ich6'> <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/> </sound> <video> <model type='cirrus' vram='9216' heads='1'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/> </video> <memballoon model='virtio'> <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/> </memballoon> </devices> <qemu:commandline> <qemu:arg value='-cpu'/> <qemu:arg value='Nehalem,+sep'/> </qemu:commandline> </domain> As discussed, I'm closing this one as a duplicate of the qemu-kvm bug for re-adding "sep" to the CPU definitions. Libvirt isn't aware of changes done to cpu features across machine types and also we don't expect removing features so we can't fix this satisfactorily for now. *** This bug has been marked as a duplicate of bug 821741 *** Side note: the feature was not exactly removed from the CPU models in qemu-kvm. The problem is that the feature was never present in any of the CPU models, because of kernel bug 821463. |