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:
In RHEL6 sp7, hotpulg/unplug is work well with libvirt. In our stree test case that hotplug/unplug device many times by libvirt, we always meet the error:
internal error no more avaliable PCI address.
But we don't see it with qemu command-line. After investigation, we observed that device's BDF in guest alway increase when we do hotplug/unplug by libvirt. But for one bus, there only 32 avaliable device ID to use. So if we try hotplug/unplug at most 32 times, libvirt will don't have available BDF for the device to use and it will fail.
With qemu command-line, qemu always use the same BDF for device to use. it seems that libvirt doesnt' release the virt slot when detach the device.
Version-Release number of selected component (if applicable):
qemu-kvm-0.12.1.2-2.90.el6.x86_64
qemu-kvm-tools-0.12.1.2-2.90.el6.x86_64
libvirt-0.8.1-13.el6.x86_64
kernel-2.6.32-44.1.el6.x86_64
How reproducible:
always
Steps to Reproduce:
1. Get RHEL6 sp7, install it as host
2. Use virtualmanager, install RHEL6 sp7 as guest
3. Use "virsh create config.xml" to boot up
4. Use "virsh attach-device "and "virsh detach-device" to hotplug/unplug at most 32 times, you wiil see the error.
Actual results:
hotplug/unplug fails
Expected results:
hotplug/unplug work well
Additional info:
Comment 2RHEL Program Management
2010-07-27 03:37:40 UTC
This issue has been proposed when we are only considering blocker
issues in the current Red Hat Enterprise Linux release.
** If you would still like this issue considered for the current
release, ask your support representative to file as a blocker on
your behalf. Otherwise ask that it be considered for the next
Red Hat Enterprise Linux release. **
The problem is that libvirt autogenerates host PCI address for each device which doesn't have it predefined in the XML. However, once the device is detached, libvirt still remembers that PCI address as occupied and selects another one on next attach-device. So it's easy to run out of PCI addresses. This problem doesn't occur when a device with predefined host PCI address is repeatedly attached/detached.
Verify this bug with libvirt-0.8.1-27.el6.x86_64, and PASSED.
Reproduce this bug with libvirt-0.8.1-21.el6.x86_64. This bug is gone on libvirt-0.8.1-27.el6.x86_64.
The following is my steps:
1. Create and start a domain.
2. Prepare a xml as following:
<interface type='network'>
<mac address='52:54:00:80:d9:bb'/>
<source network='default'/>
<model type='rtl8139'/>
</interface>
3. Hotplug/hot-unplug the PCI device at most 32 times via virsh command:
# for i in `seq 32`; do echo "---${i}---"; virsh attach-device test nic-hostput.xml; sleep 3; virsh detach-device test nic-hostput.xml; sleep 3; done
On libvirt-0.8.1-27.el6.x86_64, it works fine.
Verified this bug with rhel6 snap11, and PASSED.
relevant version:
libvirt-0.8.1-23.el6.x86_64
qemu-kvm-tools-0.12.1.2-2.109.el6.x86_64
qemu-kvm-0.12.1.2-2.109.el6.x86_64
kernel-2.6.32-63.el6.x86_64
Comment 12releng-rhel@redhat.com
2010-11-11 14:50:25 UTC
Red Hat Enterprise Linux 6.0 is now available and should resolve
the problem described in this bug report. This report is therefore being closed
with a resolution of CURRENTRELEASE. You may reopen this bug report if the
solution does not work for you.