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 2104407 - RFE: support to get thread-pool-max/thread-pool-min by domstats
Summary: RFE: support to get thread-pool-max/thread-pool-min by domstats
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: libvirt
Version: 9.1
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Virtualization Maintenance
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On: 2104404
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-07-06 07:50 UTC by Han Han
Modified: 2022-08-01 02:41 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2022-07-12 07:53:34 UTC
Type: Feature Request
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHELPLAN-127059 0 None None None 2022-07-06 08:11:53 UTC

Description Han Han 2022-07-06 07:50:00 UTC
Description of problem:
As subject

Version-Release number of selected component (if applicable):
libvirt-8.5.0-1.el9.x86_64
qemu-kvm-7.0.0-8.el9.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Start a VM with thread-pool-max/thread-pool-min properties:
➜  ~ virsh domstate rhel
running

➜  ~ virsh dumpxml rhel --xpath //iothread       
<iothread id="2" thread_pool_min="2" thread_pool_max="10"/>
<iothread id="4"/>
<iothread id="6"/>
<iothread id="8" thread_pool_min="2" thread_pool_max="32"/>
<iothread id="1"/>
<iothread id="5"/>
<iothread id="7"/>

Try querying thread-pool-max/thread-pool-min by `virsh domstats --iothread`
➜  ~ virsh domstats rhel --iothread                                        
Domain: 'rhel'
  iothread.count=7
  iothread.2.poll-max-ns=32768
  iothread.2.poll-grow=0
  iothread.2.poll-shrink=0
  iothread.8.poll-max-ns=32768
  iothread.8.poll-grow=0
  iothread.8.poll-shrink=0
  iothread.1.poll-max-ns=32768
  iothread.1.poll-grow=0
  iothread.1.poll-shrink=0
  iothread.7.poll-max-ns=32768
  iothread.7.poll-grow=0
  iothread.7.poll-shrink=0
  iothread.6.poll-max-ns=32768
  iothread.6.poll-grow=0
  iothread.6.poll-shrink=0
  iothread.5.poll-max-ns=32768
  iothread.5.poll-grow=0
  iothread.5.poll-shrink=0
  iothread.4.poll-max-ns=32768
  iothread.4.poll-grow=0
  iothread.4.poll-shrink=0

No thread-pool-max/thread-pool-min properties.

Actual results:
As above

Expected results:
As subject

Additional info:
QEMU doesn't support querying thread-pool-max/thread-pool-min as well.
The depended bug https://bugzilla.redhat.com/show_bug.cgi?id=2104404

Comment 2 Peter Krempa 2022-07-07 07:53:13 UTC
The thread pool limits is in fact configuration of a VM and not really a statistic. I don't think this is a worthwhile addition to domain statistics which is mainly focused on data that depends on the running parameters of the VM

Comment 3 Michal Privoznik 2022-07-11 01:50:26 UTC
Yeah, I don't see much value in reporting min/max values. If anything, then maybe the current size of the pool? And even then the interpretation of the number is doubtful. I mean, imagine min=1 max=10 and you'll find out that the current value is 10. Does it mean the iothread's pool is under pressure and has a lot of requests to process? No. At some point it decided to spawn 10 threads (maybe there was a spike in requests), but now there's no request to process at all. Or complete opposite and the iothread might indeed be the bottleneck.

Han, could you please expand on why you think these values should be reported?

Comment 4 Han Han 2022-07-12 03:14:57 UTC
(In reply to Michal Privoznik from comment #3)
> Yeah, I don't see much value in reporting min/max values. If anything, then
> maybe the current size of the pool? And even then the interpretation of the
> number is doubtful. I mean, imagine min=1 max=10 and you'll find out that
> the current value is 10. Does it mean the iothread's pool is under pressure
> and has a lot of requests to process? No. At some point it decided to spawn
> 10 threads (maybe there was a spike in requests), but now there's no request
> to process at all. Or complete opposite and the iothread might indeed be the
> bottleneck.
> 
> Han, could you please expand on why you think these values should be
> reported?

This idea comes when I find the properties thread-pool-max/thread-pool-min cannot be queried by domstats. 
Now I agree that reporting the current size of the pool is more useful.

Comment 5 Michal Privoznik 2022-07-12 07:01:42 UTC
But that's the thing I tired to explain in comment 3. What information can an user deduct from the current size of the pool?

Comment 6 Peter Krempa 2022-07-12 07:53:34 UTC
As noted in Comment #2, domain configuration shouldn't really be mirrored in statistics and per Comment #3, reporting of current size of the pool is not a useful statistic.

Comment 7 Han Han 2022-08-01 02:41:06 UTC
(In reply to Michal Privoznik from comment #5)
> But that's the thing I tired to explain in comment 3. What information can
> an user deduct from the current size of the pool?

Sorry for the late update. I am not clear.


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