Summary: | report error for invalid memAccess when parsing cpu | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Jincheng Miao <jmiao> |
Component: | libvirt | Assignee: | Libvirt Maintainers <libvirt-maint> |
Status: | CLOSED ERRATA | QA Contact: | Virtualization Bugs <virt-bugs> |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | 7.1 | CC: | dyuan, honzhang, jtomko, lcheng, mzhan, rbalakri |
Target Milestone: | rc | ||
Target Release: | --- | ||
Hardware: | x86_64 | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | libvirt-1.2.13-1.el7 | Doc Type: | Bug Fix |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2015-11-19 05:53:12 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: |
Description
Jincheng Miao
2014-09-25 03:25:26 UTC
Fixed upstream by: commit e02908880259c2587c7ec42d5ab5d967a7daa0a1 Author: Jincheng Miao <jmiao> AuthorDate: 2014-09-25 19:28:33 +0800 Commit: Martin Kletzander <mkletzan> CommitDate: 2014-09-26 16:03:14 +0200 conf: report error in virCPUDefParseXML When detected invalid 'memAccess', virCPUDefParseXML should report error. Resolves https://bugzilla.redhat.com/show_bug.cgi?id=1146334 Signed-off-by: Jincheng Miao <jmiao> git describe: v1.2.9-rc1-17-ge029088 contains: v1.2.9-rc2~4 Reproduced this bug with libvirt-1.2.8-16.el7.x86_64. # rpm -q libvirt libvirt-1.2.8-16.el7.x86_64 # virsh edit 7 ... <memory unit='KiB'>1024000</memory> <currentMemory unit='KiB'>1024000</currentMemory> <memoryBacking> <hugepages> <page size='2048' unit='KiB' nodeset='0'/> </hugepages> </memoryBacking> <vcpu placement='static'>4</vcpu> ... <cpu> <numa> <cell id='0' cpus='0-1' memory='512000' unit='KiB' memAccess='invalid'/> <cell id='1' cpus='2-3' memory='512000' unit='KiB'/> </numa> </cpu> ... # virsh dumpxml 7 | grep memAccess <cell id='0' cpus='0-1' memory='524288' memAccess='(null)'/> Verified with libvirt-1.2.14-1.el7.x86_64. The bug is resolved. Move to VERIFIED. 1. Set memAccess='invalid'. # cat 7.xml ... <memory unit='KiB'>1024000</memory> <currentMemory unit='KiB'>1024000</currentMemory> <memoryBacking> <hugepages> <page size='2048' unit='KiB' nodeset='0'/> </hugepages> </memoryBacking> <vcpu placement='static'>4</vcpu> ... <cpu> <numa> <cell id='0' cpus='0-1' memory='512000' unit='KiB' memAccess='invalid'/> <cell id='1' cpus='2-3' memory='512000' unit='KiB'/> </numa> </cpu> ... # virsh define 7.xml error: Failed to define domain from 7.xml error: unsupported configuration: Invalid 'memAccess' attribute value 'invalid' 2. Change memAccess from 'invalid' to 'shared'. # cat 7.xml ... <memory unit='KiB'>1024000</memory> <currentMemory unit='KiB'>1024000</currentMemory> <memoryBacking> <hugepages> <page size='2048' unit='KiB' nodeset='0'/> </hugepages> </memoryBacking> <vcpu placement='static'>4</vcpu> ... <cpu> <numa> <cell id='0' cpus='0-1' memory='512000' unit='KiB' memAccess='shared'/> <cell id='1' cpus='2-3' memory='512000' unit='KiB'/> </numa> </cpu> ... # virsh define 7.xml Domain 7 defined from 7.xml 3. Change memAccess from 'shared' to 'invalid'. # virsh edit 7 error: XML document failed to validate against schema: Unable to validate doc against /usr/share/libvirt/schemas/domain.rng Extra element cpu in interleave Element domain failed to validate content Failed. Try again? [y,n,i,f,?]: 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, 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://rhn.redhat.com/errata/RHBA-2015-2202.html |