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 1749227 - [cgroup_v2] schedinfo cmd cannot set vcpu/emulator/global/iothread period values
Summary: [cgroup_v2] schedinfo cmd cannot set vcpu/emulator/global/iothread period values
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: libvirt
Version: 8.1
Hardware: x86_64
OS: Linux
high
medium
Target Milestone: rc
: 8.1
Assignee: Pavel Hrdina
QA Contact: yisun
URL:
Whiteboard:
Depends On:
Blocks: 1749247
TreeView+ depends on / blocked
 
Reported: 2019-09-05 07:53 UTC by yisun
Modified: 2020-11-06 04:03 UTC (History)
4 users (show)

Fixed In Version: libvirt-4.5.0-35.el8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1749247 (view as bug list)
Environment:
Last Closed: 2019-11-05 20:51:43 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2019:3345 0 None None None 2019-11-05 20:51:46 UTC

Description yisun 2019-09-05 07:53:57 UTC
[cgroup_v2] schedinfo cmd cannot set vcpu/emulator/global/iothread period values

Version:
libvirt-4.5.0-34.module+el8.1.0+4158+21722aaf.x86_64

How reproducible:
100%

Steps:
1. Quota values can be set successfully by schedinfo  as follow:
[root@hp-dl320eg8-12 machine-qemu\x2d2\x2dvm2.scope]# virsh schedinfo vm2 --set vcpu_quota=333333 emulator_quota=333333 global_quota=333333 iothread_quota=333333
Scheduler      : posix
cpu_shares     : 100
vcpu_period    : 100000
vcpu_quota     : 333333
emulator_period: 100000
emulator_quota : 333333
global_period  : 100000
global_quota   : 333333
iothread_period: 100000
iothread_quota : 333333


[root@hp-dl320eg8-12 machine-qemu\x2d2\x2dvm2.scope]# cat cpu.max vcpu*/cpu.max iothread*/cpu.max emulator/cpu.max
333333 100000
333333 100000
333333 100000
333333 100000
333333 100000


2. Period values cannot be set by schedinfo  as follow:
[root@hp-dl320eg8-12 machine-qemu\x2d2\x2dvm2.scope]# virsh schedinfo vm2 --set vcpu_period=222222 emulator_period=222222 global_period=222222 iothread_period=222222
Scheduler      : posix
cpu_shares     : 100
vcpu_period    : 100000
vcpu_quota     : 333333
emulator_period: 100000
emulator_quota : 333333
global_period  : 100000
global_quota   : 333333
iothread_period: 100000
iothread_quota : 333333
<==== nothing changed

[root@hp-dl320eg8-12 machine-qemu\x2d2\x2dvm2.scope]# cat cpu.max vcpu*/cpu.max iothread*/cpu.max emulator/cpu.max
333333 100000
333333 100000
333333 100000
333333 100000
333333 100000
<===== nothing changed

3. Period values can be set by shell cmd
[root@hp-dl320eg8-12 machine-qemu\x2d2\x2dvm2.scope]# for i in {cpu.max,emulator/cpu.max,iothread1/cpu.max,vcpu0/cpu.max,vcpu1/cpu.max}; do echo '333333 222222' > $i; done
[root@hp-dl320eg8-12 machine-qemu\x2d2\x2dvm2.scope]# cat cpu.max vcpu*/cpu.max iothread*/cpu.max emulator/cpu.max
333333 222222
333333 222222
333333 222222
333333 222222
333333 222222

[root@hp-dl320eg8-12 machine-qemu\x2d2\x2dvm2.scope]# virsh schedinfo vm2
Scheduler      : posix
cpu_shares     : 100
vcpu_period    : 222222
vcpu_quota     : 333333
emulator_period: 222222
emulator_quota : 333333
global_period  : 222222
global_quota   : 333333
iothread_period: 222222
iothread_quota : 333333

Expected result:
In Step 2, the ‘schedinfo’ should be able to successfully set the period related values.

Comment 1 Pavel Hrdina 2019-09-06 07:27:11 UTC
Upstream commit:

commit 0bd4ad193d8ba7f0104f4739f19f2731e7cf9f56
Author: Pavel Hrdina <phrdina>
Date:   Thu Sep 5 11:22:11 2019 +0200

    vircgroupv2: fix setting cpu.max period

Comment 7 yisun 2019-09-17 12:00:08 UTC
Verified by auto job with libvirt-4.5.0-35.module+el8.1.0+4227+b2722cb3.x86_64:
https://libvirt-jenkins.rhev-ci-vms.eng.rdu2.redhat.com/job/libvirt-RHEL-8.1-runtest-x86_64-function-guest_resource_control/8/testReport/
(the failed case is script issue, not related with this bz)

Comment 9 errata-xmlrpc 2019-11-05 20:51:43 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://access.redhat.com/errata/RHSA-2019:3345


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