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 2186397 - Disk detach is unsuccessful while the guest is still booting
Summary: Disk detach is unsuccessful while the guest is still booting
Keywords:
Status: CLOSED COMPLETED
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: libvirt
Version: 9.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: ---
Assignee: Martin Kletzander
QA Contact: Han Han
URL:
Whiteboard:
Depends On: 2087047
Blocks: 2012096
TreeView+ depends on / blocked
 
Reported: 2023-04-13 06:53 UTC by Xuesong Zhang
Modified: 2023-11-20 10:57 UTC (History)
24 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of: 2087047
Environment:
Last Closed: 2023-11-20 10:57:06 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Reproducing script (1.96 KB, application/gzip)
2023-04-26 09:02 UTC, Han Han
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHELPLAN-154602 0 None None None 2023-04-13 16:21:45 UTC

Comment 3 Han Han 2023-04-26 09:02:50 UTC
Created attachment 1960050 [details]
Reproducing script

Reproduced on:
libvirt-9.2.0-1.el9.x86_64
qemu-kvm-7.2.0-14.el9_2.x86_64

+ virsh create rhel-9.2.xml                                                                                                                                              
Domain 'rhel-9.2' created from rhel-9.2.xml                                                                                                                              
                                                                                                                                                                         
+ sleep 3                                                                                                                                                                
+ qemu-img create /tmp/vdb 10M                                                      
Formatting '/tmp/vdb', fmt=raw size=10485760                                        
+ virsh attach-disk rhel-9.2 /tmp/vdb vdb                                           
Disk attached successfully                

+ sleep 3                                 
+ virsh detach-disk rhel-9.2 vdb                                                    
Disk detached successfully                

+ virsh dumpxml rhel-9.2 --xpath //disk/target                                      
+ grep -q vdb                             
+ declare -i RET1=0                       
+ sleep 3                                 
+ virsh detach-disk rhel-9.2 vdb                                                    
error: Failed to detach disk                                                        
error: internal error: unable to execute QEMU command 'device_del': Device virtio-disk1 is already in the process of unplug

+ declare -i RET2=1                       
+ '[' 0 -eq 0 ']'                         
+ '[' 1 -ne 0 ']'                         
+ echo FAIL                               
FAIL

Comment 4 Han Han 2023-05-11 04:42:33 UTC
PASS on libvirt-9.3.0-1.el9.x86_64 qemu-kvm-8.0.0-2.el9.x86_64 
+ virsh create rhel-9.2.xml
Domain 'rhel-9.2' created from rhel-9.2.xml

+ sleep 3
+ qemu-img create /tmp/vdb 10M
Formatting '/tmp/vdb', fmt=raw size=10485760
+ virsh attach-disk rhel-9.2 /tmp/vdb vdb
Disk attached successfully

+ sleep 3
+ virsh detach-disk rhel-9.2 vdb
Disk detached successfully

+ virsh dumpxml rhel-9.2 --xpath //disk/target
+ grep -q vdb
+ declare -i RET1=0
+ virsh event --domain rhel-9.2 --event agent-lifecycle
event 'agent-lifecycle' for domain 'rhel-9.2': state: 'connected' reason: 'channel event'
events received: 1

+ virsh detach-disk rhel-9.2 vdb
Disk detached successfully

+ declare -i RET2=0
+ '[' 0 -eq 0 ']'
+ '[' 0 -ne 0 ']'
+ echo PASS
PASS
+ exit 0

Comment 5 Thomas Huth 2023-11-20 10:57:06 UTC
Now that 9.3 has been released, I think this can be closed.


Note You need to log in before you can comment on or make changes to this bug.