Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
libvirt should forbid to hot-plug vcpus while guest is in booting phase
Version-Release number of selected component (if applicable):
libvirt-0.10.2-32.el6.x86_64
qemu-kvm-rhev-0.12.1.2-2.423.el6.x86_64
kernel-2.6.32-457.el6.x86_64
How reproducible:
100%
Steps to Reproduce:
1. prepare one shutoff guest, edit the cpu settings like following one.
......
<vcpu placement='static' current='2'>4</vcpu>
......
2. start the guest
3. check the vcpu info
# virsh vcpucount rhel6.5
maximum config 4
maximum live 4
current config 2
current live 2
4. while the guest is still in booting phase, hot-plug the vcpu to guest.
# virsh setvcpus rhel6.5 3
# virsh vcpucount rhel6.5
maximum config 4
maximum live 4
current config 2
current live 3
5. after the guest finished booting up, check in the guest, the cpu didn't be hot-pluged successfully.
In guest
# cat /proc/cpuinfo|grep processor|wc -l
2
Actual results:
the vcpu number in step 4 and step 5 are different, hot-plug vcpu fail in step 4 actually, but the vcpu number in hypervisor is changed to 3.
Expected results:
in step 4, it's better let libvirt forbid hot-plug vcpus while guest is in booting phase.
Addtional info:
From the following bug, you can see that hot-plug vcpus via qemu will be failed also while guest is in booting phase.
https://bugzilla.redhat.com/show_bug.cgi?id=807508
So, suggest to forbid hot-plug vcpu while guest is in booting phase in libvirt.
Seems libvirt or qemu can't determine whether one guest is full booted up.
So suggest to add this know issue in the man page of virsh setvcpus command.
The explain of virsh command setvcpus can be found in latest libvirt-0.10.2-34.el6.
# man virsh
...
setvcpus domain count [--maximum] [[--config] [--live] | [--current]]
[--guest]
...
If --live is specified, the guest domain must be active, and the
change takes place immediately. Both the --config and --live flags
may be specified together if supported by the hypervisor. If this
command is run before the guest has finished booting, the guest may
fail to process the change.
...
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.
http://rhn.redhat.com/errata/RHBA-2014-1374.html