Bug 1941594
Summary: | <cachetune id='' attribute is not documented and not covered by the XML schema | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux Advanced Virtualization | Reporter: | Lili Zhu <lizhu> |
Component: | libvirt | Assignee: | khanicov |
Status: | CLOSED ERRATA | QA Contact: | Luyao Huang <lhuang> |
Severity: | low | Docs Contact: | |
Priority: | low | ||
Version: | 8.4 | CC: | jdenemar, khanicov, lmen, mprivozn, pkrempa, virt-maint, xuzhang, yalzhang |
Target Milestone: | rc | Keywords: | Triaged, Upstream |
Target Release: | 8.4 | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | libvirt-7.6.0-1.module+el8.5.0+12097+2c77910b | Doc Type: | If docs needed, set a value |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2021-11-16 07:52:17 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: | 7.6.0 |
Embargoed: |
Description
Lili Zhu
2021-03-22 13:05:19 UTC
The 'id' of <cachetune> seems to be an output-only element according to the code. Why are you trying to set it? There are other problems though. E.g. it's not documented at all. (In reply to Peter Krempa from comment #1) > The 'id' of <cachetune> seems to be an output-only element according to the > code. Why are you trying to set it? Hi, I am a newbie to this part, when I try to edit the guest xml with host cache id following some document The doc: prepare a running guest, with the following xml: <cputune> <vcpupin vcpu='0' cpuset='1,3-4'/> <cachetune vcpus='0-3' id='vcpus_0-3'> <monitor level='3' vcpus='0'/> </cachetune> </cputune> When the guest is started, the xml is just as the above. But when I try to edit the guest with the xml, it can not work. I thought I can edit the guest according to the started guest xml, is it a misunderstanding? Thanks very much. Well, with output-only elements it doesn't really matter what you set for it, it will be ignored when the XML is parsed. Nevertheless there are following problems: - cachentune 'id' attribute should be in schema even when it's output only - the attribute is not documented at all - it would be great to have a unit test in the libvirt codebase testing the output value Patches proposed on the list: https://listman.redhat.com/archives/libvir-list/2021-July/msg00441.html Patches v2 proposed on the list: https://listman.redhat.com/archives/libvir-list/2021-July/msg00513.html Merged upstream as: b78bfd4c54 docs: Allow 'id' attribute for 'cachetune' element b0b5820efe genericxml2xmltest: Modify cachetune test to include id v7.5.0-131-gb0b5820efe Verify this bug with libvirt-daemon-7.6.0-2.module+el8.5.0+12219+a5ea13d2.x86_64: 1. prepare a xml file which include cachetune element with id: # cat vm1.xml ... <vcpu placement='static' cpuset='0-2' current='2'>5</vcpu> <cputune> <vcpupin vcpu='0' cpuset='1,3-4'/> <cachetune vcpus='0-3' id='vcpus_0-3'> <monitor level='3' vcpus='0'/> </cachetune> </cputune> ... 2. use virt-xml-validate validate xml: # virt-xml-validate vm1.xml vm1.xml validates 3. check document in /usr/share/doc/libvirt-docs/html/formatdomain.html ... The optional, output only <span class="docutils literal">id</span> attribute identifies cache uniquely. ... Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (virt:av bug fix and enhancement update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2021:4684 |