Bug 1236440
| Summary: | Guest can not start with eoi attribute ('on' or 'off') in apic element | |||
|---|---|---|---|---|
| Product: | Red Hat Enterprise Linux 8 | Reporter: | Dan Zheng <dzheng> | |
| Component: | libvirt | Assignee: | Daniel Henrique Barboza (IBM) <dbarboza> | |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | Dan Zheng <dzheng> | |
| Severity: | low | Docs Contact: | ||
| Priority: | low | |||
| Version: | 8.0 | CC: | abologna, dbarboza, dgibson, dyuan, dzheng, gsun, jdenemar, jsuchane, knoel, lhuang, mzhan, yalzhang | |
| Target Milestone: | rc | Keywords: | TestOnly, Triaged | |
| Target Release: | 8.3 | Flags: | pm-rhel:
mirror+
|
|
| Hardware: | ppc64le | |||
| OS: | Linux | |||
| Whiteboard: | ||||
| Fixed In Version: | Doc Type: | If docs needed, set a value | ||
| Doc Text: | Story Points: | --- | ||
| Clone Of: | ||||
| : | 1817955 1829729 (view as bug list) | Environment: | ||
| Last Closed: | 2020-12-03 11:01:08 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: | ||||
| Bug Blocks: | 1829729 | |||
|
Description
Dan Zheng
2015-06-29 02:36:20 UTC
This should be related to bug 1235511. https://bugzilla.redhat.com/show_bug.cgi?id=1235511 With setting 'power8' in cpu model as below, the guest can start correctly. <model fallback='allow'>power8</model> Setting APIC options makes no sense for a Power system, since the APIC is x86 specific. So, I think all that needs to happen here is a more helpful error message from libvirt. (In reply to David Gibson from comment #5) > Setting APIC options makes no sense for a Power system, since the APIC is > x86 specific. > > So, I think all that needs to happen here is a more helpful error message > from libvirt. Seems like QEMU's behavior has changed with respect to these flags, eg. /usr/libexec/qemu-kvm \ -nographic -no-user-config -nodefaults \ -M pseries,accel=kvm \ -cpu POWER8E,+kvm_pv_eoi used to fail with the message reported above, but now it seems like unrecognized features are simply being ignored, even with something like /usr/libexec/qemu-kvm \ -nographic -no-user-config -nodefaults \ -M pseries,accel=kvm \ -cpu POWER8E,-some,completely=random,+crap Was this changed on purpose? It would of course be better to catch such configuration errors at the libvirt level rather than letting users create a configuration that results in a nonsensical QEMU command line, but I'm wondering whether it's a good idea for QEMU to be so relaxed when it comes to CPU flags... No, it wasn't changed deliberately. That must have been a side effect of something else, though I'm not immediately sure what. I'll try to bisect and find out what changed this. I finally got around to investingating this more deeply. I can't actually find any upstream versions exhibiting the problem, nor did the most recent 2.6 based downstream version when built from source. Can we retry with the latest release qemu-kvm-rhev and see if this still has the problem. Retest with packages:
qemu-kvm-rhev-2.8.0-1.el7.ppc64le
kernel-3.10.0-537.el7.ppc64le
libvirt-2.5.0-1.el7.ppc64le
OS tree: RHEL-7.4-20170106.n.1
1. Guest uses below XML
<features>
<acpi/>
<apic eoi='on'/>
<pae/>
</features>
# virsh start test
error: Failed to start domain test
error: internal error: process exited while connecting to monitor: 2017-01-12T08:08:27.696881Z qemu-kvm: Expected key=value format, found +kvm_pv_eoi.
2. Guest uses below XML
<features>
<acpi/>
<apic eoi='off'/>
<pae/>
</features>
# virsh start test
error: Failed to start domain test
error: internal error: process exited while connecting to monitor: 2017-01-12T08:13:34.026009Z qemu-kvm: Expected key=value format, found -kvm_pv_eoi.
===> The error message is not accurate.
3. Guest uses below XML
<features>
<acpi/>
<pae/>
</features>
or
<features>
<acpi/>
<apic/>
<pae/>
</features>
# virsh start test
Domain test started
qemu 46132 1 99 03:29 ? 00:00:10 /usr/libexec/qemu-kvm -name guest=test,debug-threads=on -S -object secret,id=masterKey0,format=raw,file=/var/lib/libvirt/qemu/domain-9-test/master-key.aes -machine pseries-rhel7.3.0,accel=kvm,usb=off,dump-guest-core=off -cpu host -m 1024 -realtime mlock=off -smp 2,sockets=2,cores=1,threads=1 -u
===> With both XMLs above, the guest can be started, and 'apic' is ignored in case of the second XML.
Patch was sent to the mailing list: https://www.redhat.com/archives/libvir-list/2020-March/msg00717.html The approach is the one from comment #5: refuse to launch the guest and provide a more helpful error message for the user. Fix merged upstream:
commit dbda73ff27cf185fb5db498cc4db281b2d76778d
Author: Daniel Henrique Barboza <danielhb413>
Date: Tue Mar 24 14:33:21 2020 -0300
qemu: avoid launching non-x86 guests with APIC-EOI setting
v6.1.0-276-gdbda73ff27
Package: libvirt-6.0.0-25.module+el8.3.0+7176+57f10f42.ppc64le 1.Define a guest with eoi: Add below in xml and define a guest, then an error is raised as below. - PASS <features> <acpi/> <apic eoi='on'/> <pae/> </features> # virsh define dz.xml error: Failed to define domain from dz.xml error: unsupported configuration: The 'eoi' attribute of the 'apic' feature is not supported for architecture 'ppc64le' or machine type 'pseries-rhel8.2.0' 2. Edit a guest with eoi Add below into a guest xml, then an error is raised as below. - PASS <features> <acpi/> <apic eoi='off'/> <pae/> </features> # virsh edit dz1 error: unsupported configuration: The 'eoi' attribute of the 'apic' feature is not supported for architecture 'ppc64le' or machine type 'pseries-rhel8.2.0' So I mark it verified. |