[tuned] #47: Create new plugin for process scheduling/priority tuning
by fedora-badges
#47: Create new plugin for process scheduling/priority tuning
--------------------------+--------------------
Reporter: jeder | Owner:
Type: enhancement | Status: new
Priority: major | Component: daemon
Version: 2.0 | Keywords:
Blocked By: | Blocking:
--------------------------+--------------------
We have an init-based service now that, upon boot, applies some scheduler
tuning to regexes matching threads.
Below is an example:
# Format is: <groupname>:<sched>:<prio>:affinity:<regex>
kthreads:*:1:*:\[.*\]$
watchdog:f:99:*:\[watchdog.*\]
migration:f:99:*:\[migration\/.*\]
softirq:f:70:*:\[.*(softirq|sirq).*\]
softirq-net-tx:f:75:*:\[(softirq|sirq)-net-tx.*\]
softirq-net-rx:f:75:*:\[(softirq|sirq)-net-rx.*\]
softirq-sched:f:1:*:\[(softirq|sirq)-sched\/.*\]
rpciod:f:65:*:\[rpciod.*\]
lockd:f:65:*:\[lockd.*\]
nfsd:f:65:*:\[nfsd.*\]
hardirq:f:85:*:\[(irq|IRQ)[\-_/].*\]
We would like to move this functionality from the init system to a tuned
profile, but it doesn't seem possible with the current tuned
capabilities/plugins.
In addition to one-shot tuning during profile load, there is also a use-
case for monitoring new processes that are created, and applying this
tuning.
This could be a watchdog/scanning behavior in tuned daemon (not preferred
because it creates background noise), or something more clever using perf
events or even LD_PRELOAD of exec function call.
--
Ticket URL: <https://fedorahosted.org/tuned/ticket/47>
tuned <https://fedorahosted.org/tuned/>
A daemon that performs monitoring and adaptive configuration of devices in the system.
9 years, 6 months
RE: power-management Digest, Vol 28, Issue 2
by Hase, Jin
Hi Jaroslav
Thank you for your commit.
I will create a patch by "git format-patch" if I submit in the next time.
I understand that intel_pstate has only "performance" or "powersave"
governor, and balanced profile and powersave profile don't work as
expected(These profiles use ondemand or conservative governor.)
So, I set "intel_pstate=disable" to boot parameter in my server.
I think that intel_pstate isn't suitable for auto-tuning of P-State.
Regards,
Jin Hase
> -----Original Message-----
> From: power-management-bounces(a)lists.fedoraproject.org
> [mailto:power-management-bounces@lists.fedoraproject.org] On Behalf Of
> power-management-request(a)lists.fedoraproject.org
> Sent: Tuesday, July 22, 2014 9:00 PM
> To: power-management(a)lists.fedoraproject.org
> Subject: power-management Digest, Vol 28, Issue 2
>
> Send power-management mailing list submissions to
> power-management(a)lists.fedoraproject.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
> https://admin.fedoraproject.org/mailman/listinfo/power-manageme
> nt
> or, via email, send a message with subject or body 'help' to
> power-management-request(a)lists.fedoraproject.org
>
> You can reach the person managing the list at
> power-management-owner(a)lists.fedoraproject.org
>
> When replying, please edit your Subject line so it is more specific than
> "Re: Contents of power-management digest..."
>
>
> Today's Topics:
>
> 1. Re: [patch] balanced: used conservative CPU governor
> (Jaroslav Skarvada)
> 2. Re: [patch] balanced: used conservative CPU governor
> (Jaroslav Skarvada)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Tue, 22 Jul 2014 05:50:36 -0400 (EDT)
> From: Jaroslav Skarvada <jskarvad(a)redhat.com>
> To: Fedora Power Management SIG mailing list
> <power-management(a)lists.fedoraproject.org>
> Subject: Re: [patch] balanced: used conservative CPU governor
> Message-ID:
> <2012808973.23545325.1406022635996.JavaMail.zimbra(a)redhat.com>
> Content-Type: text/plain; charset=utf-8
>
>
>
> ----- Original Message -----
> > I have an idea which improves balanced profile in tuned.
> > This is the first time that I submit patch, so please point out if my
> > procedure is wrong.
> >
> Thanks, it makes sense. Please note this will work only on older machines
> with acpi-cpufreq. On recent machines with intel_pstate there is no
> conservative governor.
> But tuned can cope with this. Please could you resend the patch created by
> "git format-patch" (including the comment). In such case you will have credit
> in the git
>
> thanks & regards
>
> Jaroslav
>
>
> ------------------------------
>
> Message: 2
> Date: Tue, 22 Jul 2014 06:12:00 -0400 (EDT)
> From: Jaroslav Skarvada <jskarvad(a)redhat.com>
> To: Fedora Power Management SIG mailing list
> <power-management(a)lists.fedoraproject.org>
> Subject: Re: [patch] balanced: used conservative CPU governor
> Message-ID:
> <671458635.23551618.1406023920711.JavaMail.zimbra(a)redhat.com>
> Content-Type: text/plain; charset=utf-8
>
> > Please could you resend
> > the patch created by "git format-patch" (including the comment). In
> > such case you will have credit in the git
> >
> If you don't mind I slightly re-formatted your patch to apply with 'git am',
> commit:
>
> https://git.fedorahosted.org/cgit/tuned.git/commit/?id=b2897d9c1cfea988
> 0bd64660bf519bdf04117f9c
>
> thanks & regards
>
> Jaroslav
>
>
> ------------------------------
>
> _______________________________________________
> power-management mailing list
> power-management(a)lists.fedoraproject.org
> https://admin.fedoraproject.org/mailman/listinfo/power-management
>
>
> End of power-management Digest, Vol 28, Issue 2
> ***********************************************
9 years, 9 months
[patch] balanced: used conservative CPU governor
by Hase, Jin
I have an idea which improves balanced profile in tuned.
This is the first time that I submit patch, so please
point out if my procedure is wrong.
---
balanced: used conservative CPU governor
In my testing, balanced profile's efficiency is almost as same(*1) as
powersave profile on my server using Xeon-E5.
I think tuned should make difference between balanced profile and powersave
profile. IOW, balanced profile should show better performance and worse power
consumption than powersave profile.
One of root causes is that detailed settings of P-State and C-State are
almost same between balanced profile and powersave profile.
This patch proposes that making "balanced"'s CPU governer to be conservative.
This will make difference between balanced and powersave(*2).
[Measurement result]
- Load testing tool
JdbcRunner(Database Model)
- Hardware
12core(Xeon E5-2650L 1.80GHz)/8GB Memory/SSD 100GB/1Gbit Network
(But I limit the number of core to "4" by BIOS because of adjusting
CPU load)
- Software
kernel-3.10.0-123.el7.x86_64, tuned-2.3.0-11.el7.noarch
- Throughput, latency and power consumption
(power consumption is measured by ipmitool sensor)
| Throughput | Latency | Power Consumption
Profile | (tpm) | (msec) | on Server (Watt)
--------------------------------------------------------------
(*1)powersave | 8,495 | 28 | 111.2
--------------------------------------------------------------
(*1)balanced | 8,340 | 29 | 111.6
--------------------------------------------------------------
(*2)This patch | 9,284 | 25 | 118.8
--------------------------------------------------------------
throughput- | 10,464 | 25 | 128.0
performance | | |
--------------------------------------------------------------
latency- | 10,911 | 23 | 133.2
performance | | |
--------------------------------------------------------------
- P-State and C-State(measured by turbostat)
| CPU freq| C-State
Profile | (GHz) | (%C0) | (%C1) | (%C3) | (%C6) | (%C7)
--------------------------------------------------------------
powersave | 1.31 | 59.45 | 28.55 | 1.72 | 0 | 10.25
--------------------------------------------------------------
balanced | 1.38 | 61.63 | 30.02 | 0.77 | 0 | 7.56
--------------------------------------------------------------
This patch | 1.81 | 51.27 | 39.91 | 1.78 | 0 | 7.04
--------------------------------------------------------------
throughput- | 2.25 | 46.14 | 52.44 | 0.43 | 0 | 0.97
performance | | | | | |
--------------------------------------------------------------
latency- | 2.30 | 48.36 | 51.64 | 0 | 0 | 0
performance | | | | | |
--------------------------------------------------------------
- CPU utilization(measured by sar)
Profile | %user | %sys | %iowait | %idle
---------------------------------------------------
powersave | 36.69 | 13.32 | 5.25 | 44.74
---------------------------------------------------
balanced | 38.94 | 13.88 | 4.07 | 43.12
---------------------------------------------------
This patch | 42.78 | 14.53 | 5.97 | 36.72
---------------------------------------------------
throughput- | 33.51 | 12.29 | 7.14 | 47.06
performance | | | |
---------------------------------------------------
latency- | 34.58 | 11.71 | 7.89 | 45.82
performance | | | |
---------------------------------------------------
Signed-off-by: Jin Hase <hase.jin(a)jp.fujitsu.com>
1 file changed, 1 insertion(+), 1 deletion(-)
--- profiles/balanced/tuned.conf.orig
+++ profiles/balanced/tuned.conf
@@ -3,7 +3,7 @@
#
[cpu]
-governor=ondemand
+governor=conservative
energy_perf_bias=normal
[audio]
9 years, 9 months