Bug 1821592
| Summary: | Unable to start guest with a reduced number of active CPUs and multiple diesb [rhel-8.2.0.z] | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux Advanced Virtualization | Reporter: | Oneata Mircea Teodor <toneata> |
| Component: | libvirt | Assignee: | Daniel Berrangé <berrange> |
| Status: | CLOSED ERRATA | QA Contact: | jiyan <jiyan> |
| Severity: | medium | Docs Contact: | |
| Priority: | medium | ||
| Version: | 8.2 | CC: | berrange, dyuan, jdenemar, jiyan, jsuchane, lhuang, lmen, mtessun, pkrempa, toneata, virt-maint, xuzhang, yalzhang |
| Target Milestone: | rc | Keywords: | Triaged |
| Target Release: | 8.3 | Flags: | pm-rhel:
mirror+
|
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | libvirt-6.0.0-17.1.el8 | Doc Type: | If docs needed, set a value |
| Doc Text: | Story Points: | --- | |
| Clone Of: | 1813395 | Environment: | |
| Last Closed: | 2020-06-15 14:10: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: | commit in BZ |
| Embargoed: | |||
| Bug Depends On: | 1813395 | ||
| Bug Blocks: | 1785207, 1819060 | ||
Also tested the following testing scenarios with libvirt-6.0.0-17.1.module+el8.2.0+6587+cab4dcee.x86_64.
Version:
kernel-4.18.0-193.el8.x86_64
libvirt-6.0.0-17.1.module+el8.2.0+6587+cab4dcee.x86_64
qemu-kvm-4.2.0-19.module+el8.2.0+6296+6b821950.x86_64
Steps:
*** S1: Set dies=1 ***
1. Prepare a shutdown VM with the following conf
# virsh domstate test82
shut off
# virsh dumpxml test82 --inactive
...
<vcpu placement='static' current='24'>96</vcpu>
<iothreads>2</iothreads>
<iothreadids>
<iothread id='2'/>
<iothread id='1'/>
</iothreadids>
<cputune>
<shares>2048</shares>
<vcpupin vcpu='2' cpuset='0-7'/>
<vcpupin vcpu='19' cpuset='7,170,191'/>
<emulatorpin cpuset='1-3'/>
<iothreadpin iothread='2' cpuset='7-8'/>
<iothreadpin iothread='1' cpuset='5-6'/>
</cputune>
<numatune>
<memory mode='strict' nodeset='0-2'/>
<memnode cellid='0' mode='strict' nodeset='1'/>
<memnode cellid='2' mode='preferred' nodeset='2'/>
</numatune>
...
<cpu mode='host-model' check='partial'>
<topology sockets='4' dies='1' cores='4' threads='6'/>
<numa>
<cell id='0' cpus='0,4-7' memory='512000' unit='KiB'/>
<cell id='1' cpus='1,8-10,12-15' memory='512000' unit='KiB' memAccess='shared'>
<distances>
<sibling id='1' value='10'/>
</distances>
</cell>
<cell id='2' cpus='2,11' memory='512000' unit='KiB' memAccess='shared'>
<distances>
<sibling id='2' value='10'/>
</distances>
</cell>
<cell id='3' cpus='3' memory='512000' unit='KiB'/>
</numa>
</cpu>
2. Start VM
# virsh start test82
Domain test82 started
# ps -ef | grep test82
-smp 24,maxcpus=96,sockets=4,dies=1,cores=4,threads=6
# virsh vcpucount test82
maximum config 96
maximum live 96
current config 24
current live 24
# virsh console test82
Connected to domain test82
Escape character is ^]
Red Hat Enterprise Linux 8.2 (Ootpa)
Kernel 4.18.0-193.el8.x86_64 on an x86_64
localhost login: root
Password:
Last login: Thu May 14 15:43:39 on ttyS0
[root@localhost ~]# lscpu
Architecture: x86_64
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPU(s): 24
On-line CPU(s) list: 0-23
Thread(s) per core: 2
Core(s) per socket: 10
Socket(s): 1
NUMA node(s): 4
Vendor ID: GenuineIntel
CPU family: 6
Model: 85
Model name: Intel Xeon Processor (Cascadelake)
...
NUMA node0 CPU(s): 0,4-7,16-23
NUMA node1 CPU(s): 1,8-10,12-15
NUMA node2 CPU(s): 2,11
NUMA node3 CPU(s): 3
3. Test hot-plugging/unplugging
# virsh setvcpus test82 83
# virsh setvcpu test82 37 --disable
# virsh setvcpu test82 67 --disable
# virsh setvcpu test82 49 --disable
# virsh setvcpu test82 91 --enable
# virsh vcpucount test82
maximum config 96
maximum live 96
current config 24
current live 81
# virsh console test82
[root@localhost ~]# lscpu
Architecture: x86_64
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPU(s): 81
On-line CPU(s) list: 0-36,38-48,50-66,68-83
Thread(s) per core: 3
Core(s) per socket: 5
Socket(s): 4
NUMA node(s): 4
[root@localhost ~]# cat /sys/devices/system/cpu/cpu29/online
1
[root@localhost ~]# echo 0 > /sys/devices/system/cpu/cpu29/online
[ 390.246373] Unregister pv shared memory for cpu 29
[ 390.250951] smpboot: CPU 29 is now offline
[root@localhost ~]# lscpu
Architecture: x86_64
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPU(s): 81
On-line CPU(s) list: 0-28,30-36,38-48,50-66,68-83
Off-line CPU(s) list: 29
Thread(s) per core: 3
Core(s) per socket: 5
Socket(s): 4
NUMA node(s): 4
3. Test hypervisor-cpu-baseline with dumpxml/capabilities file
# virsh capabilities >> cap.xml
# virsh hypervisor-cpu-baseline cap.xml
Output the right result here
# virsh dumpxml test82 >> dom.xml
# virsh hypervisor-cpu-baseline dom.xml
Output the right result here
4. Test managedsave cmd
# virsh managedsave test82
Domain test82 state saved by libvirt
# virsh start test82
Domain test82 started
# virsh console test82
Connected to domain test82
Escape character is ^]
[root@localhost ~]#
[root@localhost ~]#
[root@localhost ~]# lscpu
Architecture: x86_64
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPU(s): 81
On-line CPU(s) list: 0-28,30-36,38-48,50-66,68-83
*** S2: Set dies=3 ***
Execute same test scenarios with S1, all passed.
<vcpu placement='static' current='64'>96</vcpu>
<topology sockets='4' dies='3' cores='2' threads='4'/>
# virsh setvcpus test82 82
# virsh setvcpu test82 94 --enable
*** S3: Set dies=5 ***
Execute same test scenarios with S1, all passed.
<vcpu placement='static' current='156'>160</vcpu>
<topology sockets='4' dies='5' cores='2' threads='4'/>
# virsh setvcpu test82 159 --enable
# virsh setvcpu test82 98 --disable
All test results are passed, move this bug to be verified.
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://access.redhat.com/errata/RHBA-2020:2552 |
Reproduced this issue with libvirt-6.0.0-17.module+el8.2.0+6257+0d066c28.x86_64 and verified this issue with libvirt-6.0.0-17.1.module+el8.2.0+6587+cab4dcee.x86_64. Version: libvirt-6.0.0-17.module+el8.2.0+6257+0d066c28.x86_64 qemu-kvm-4.2.0-19.module+el8.2.0+6296+6b821950.x86_64 kernel-4.18.0-193.el8.x86_64 Steps: 1. Prepare a shutdown VM with the following conf # virsh domstate test82 shut off # virsh dumpxml test82 --inactive <vcpu placement='static' current='24'>32</vcpu> ... <cpu mode='host-model' check='partial'> <topology sockets='2' dies='2' cores='4' threads='2'/> </cpu> 2. Start VM # virsh start test82 error: Failed to start domain test82 error: internal error: qemu didn't report thread id for vcpu '16' 3. Upgrade libvirt and restart libvirtd service # yum upgrade libvirt* -y # rpm -qa libvirt libvirt-6.0.0-17.1.module+el8.2.0+6587+cab4dcee.x86_64 # systemctl restart libvirtd 4. Start the VM again # virsh start test82 Domain test82 started # ps -ef | grep test82 -smp 24,maxcpus=32,sockets=2,dies=2,cores=4,threads=2 # virsh vcpucount test82 maximum config 32 maximum live 32 current config 24 current live 24 # virsh console test82 Connected to domain test82 Escape character is ^] Red Hat Enterprise Linux 8.2 (Ootpa) Kernel 4.18.0-193.el8.x86_64 on an x86_64 localhost login: root Password: [root@localhost ~]# lscpu Architecture: x86_64 CPU op-mode(s): 32-bit, 64-bit Byte Order: Little Endian CPU(s): 24 On-line CPU(s) list: 0-23 Thread(s) per core: 2 Core(s) per socket: 6 Socket(s): 2 NUMA node(s): 1 Vendor ID: GenuineIntel CPU family: 6 Model: 85 Model name: Intel Xeon Processor (Cascadelake) 5. Based on step-4, test hot-plugging/unplugging # virsh setvcpus test82 27 # virsh setvcpu test82 25 --disable # virsh setvcpu test82 31 --enable # virsh vcpucount test82 maximum config 32 maximum live 32 current config 24 current live 27 # lscpu Architecture: x86_64 CPU op-mode(s): 32-bit, 64-bit Byte Order: Little Endian CPU(s): 27 On-line CPU(s) list: 0-24,26,27 Thread(s) per core: 1 Core(s) per socket: 7 Socket(s): 2 NUMA node(s): 1 Vendor ID: GenuineIntel CPU family: 6 Model: 85 Model name: Intel Xeon Processor (Cascadelake)