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.

Bug 1218145

Summary: vm deadlock when deleting a nonexistent iothread with --config
Product: Red Hat Enterprise Linux 7 Reporter: Luyao Huang <lhuang>
Component: libvirtAssignee: Ján Tomko <jtomko>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.2CC: dyuan, fjin, honzhang, jtomko, mzhan, rbalakri
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: libvirt-1.2.16-1.el7 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-11-19 06:30:01 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:
Embargoed:

Description Luyao Huang 2015-05-04 09:34:56 UTC
description of problem:
vm deadlock when del an unexist iothread with --config

Version-Release number of selected component (if applicable):
libvirt-1.2.15-1.el7.x86_64
qemu-kvm-rhev-2.2.0-8.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1.
prepare a running vm:

# virsh list
 Id    Name                           State
----------------------------------------------------
 4     test3                          running

2.
# virsh iothreaddel test3 1234567891 --config
error: invalid argument: cannot find IOThread '1234567891' in persistent iothreadids

# virsh iothreaddel test3 1234567891 --current
error: Timed out during operation: cannot acquire state change lock (held by remoteDispatchDomainDelIOThread)

Actual results:
 vm deadlock when del an unexist iothread with --config

Expected results:
no deadlock

infomation:

Comment 1 Luyao Huang 2015-05-04 09:38:17 UTC
Patch already send to upstream:

https://www.redhat.com/archives/libvir-list/2015-May/msg00016.html

Comment 2 Ján Tomko 2015-05-04 10:22:29 UTC
Pushed upstream:
commit 3f7cad7a8fb5f646a924975517ff3f04c723540b
Author:     Luyao Huang <lhuang>
CommitDate: 2015-05-04 12:18:55 +0200

    qemu: fix the vm deadlock when deleting a nonexistent iothread
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1218145
    
    Jump to endjob instead of cleanup to fix this deadlock.
    
    Signed-off-by: Luyao Huang <lhuang>

git describe: v1.2.15-8-g3f7cad7

Comment 4 Fangge Jin 2015-08-20 08:57:18 UTC
I can reproduce this bug on build libvirt-1.2.15-1.el7.x86_64

Verify it on build libvirt-1.2.17-5.el7.x86_64

Steps:
1.Prepare a guest with iothreadinfo like below:
# virsh iothreadinfo rhel7d2
 IOThread ID     CPU Affinity   
---------------------------------------------------
 1               4
 2               6
 6               1-4,6
 8               1-4,6

2.# virsh iothreaddel rhel7d2 12345 --config
error: invalid argument: cannot find IOThread '12345' in persistent iothreadids

3.# virsh iothreaddel rhel7d2 12345 --current
error: invalid argument: cannot find IOThread '12345' in iothreadids list

4.# virsh iothreaddel rhel7d2 1 --current

5.# virsh iothreadinfo rhel7d2 
 IOThread ID     CPU Affinity   
---------------------------------------------------
 2               6
 6               1-4,6
 8               1-4,6

Comment 6 errata-xmlrpc 2015-11-19 06:30:01 UTC
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