-
Bug
-
Resolution: Done-Errata
-
Undefined
-
rhel-9.4
-
libvirt-10.0.0-3.el9
-
Yes
-
Moderate
-
Regression
-
rhel-sst-virtualization
-
ssg_virtualization
-
26
-
None
-
QE ack, Dev ack
-
False
-
-
None
-
None
-
Pass
-
Automated
-
None
What were you trying to do that didn't work?
Non-root user connects to libvirt daemon, terminate the cmd during the authentication process. Then root user run cmd "virsh list", and the cmd hungs.
Please provide the package NVR for which bug is seen:
libvirt-9.9.0-1.el9.x86_64
How reproducible:100%
Steps to reproduce
1. set below setting in /etc/libvirt/virtqemud.conf
log_level = 1
log_outputs = "1:file:/var/log/libvirt/libvirtd.log"
2. restart virtqemud
systemctl restart virtqemud
3. use gdb to attach to virtqemud process, set break point at func "virNetServerSetClientAuthenticated" then continue the process
# gdb -p `pidof virtqemud`
(gdb) br virNetServerSetClientAuthenticated
Breakpoint 2 at 0x7f7b549faad0
(gdb) c
Continuing.
4. at another terminal, connect qemu:///system with non-root user, input right user and passwd, after the authentication complete(virsh client will be stopped at that point since br set in gdb), enter "Ctrl+c"
$ virsh -c qemu:///system
==== AUTHENTICATING FOR org.libvirt.unix.manage ====
System policy prevents management of local virtualized systems
Authenticating as: root
Password:
==== AUTHENTICATION COMPLETE ====
^C
5. Then in gdb terminal of step3, enter 'c' to continue
Thread 8 "prio-rpc-virtqe" hit Breakpoint 2, 0x00007f7b549faad0 in virNetServerSetClientAuthenticated () from /lib64/libvirt.so.0
(gdb) c
Continuing.
Actual results
6. Check the libvirt daemon log about nclient, we could see the nclients and nclients_unauth all equal 1.
# cat /var/log/libvirt/libvirtd.log | grep -i nclient
2024-01-02 03:31:32.594+0000: 11865: debug : virNetServerCheckLimits:269 : Checking client-related limits to re-enable or temporarily suspend services: nclients=1 nclients_max=5000 nclients_unauth=1 nclients_unauth_max=20
7. root user run cmd "virsh list" and the cmd hungs
# virsh list
Expected results
1. the libvirt daemon log about nclient, the nclients and nclients_unauth should change to 0.
2. root user and run cmd "virsh list" should not hung
Additional info
1. If non-root user run cmd "virsh list" and the cmd get result successfully
$ virsh list
Id Name State
--------------------
2. Similar issue please check the bug:
- links to
-
RHBA-2023:125049 libvirt bug fix and enhancement update
- mentioned on