Bug 1028122

Summary: Improve the responsiveness of tuned-adm
Product: Red Hat Enterprise Linux 7 Reporter: Jaroslav Škarvada <jskarvad>
Component: tunedAssignee: Jaroslav Škarvada <jskarvad>
Status: CLOSED CURRENTRELEASE QA Contact: Branislav Blaškovič <bblaskov>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.0CC: bblaskov, jeder, jscotka, jskarvad, perfbz
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: tuned-2.3.0-2.el7 Doc Type: Bug Fix
Doc Text:
Cause: The recent tuned and python update fixed the bug that tuned was waking up the system each 50 milliseconds. As a consequence the tuned started to wake the system only after 10 seconds. This improved the power consumption but made the responsiveness of tuned worse. Consequence: Tuned could react to commands in up to 10 seconds. Fix: The main thread code was slightly reworked and the interval lowered to 1 second. Result: Tuned can now react to commands in up to 1 second with still slightly low overhead. In case you need even lower overhead and you don't mind to have longer response times, you can fine tune the sleep_interval settings in the global Tuned configuration file (/etc/tuned/tuned-main.conf). For details, see the manual page.
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-06-13 11:25:14 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jaroslav Škarvada 2013-11-07 17:29:32 UTC
Description of problem:
Tuned-2.3.0 is more power efficient, because it is waking up system only once per 10 seconds instead of previous tuned which was waking up the system 20 times per second, but it's responsiveness is worse. It can react to commands in up to 10 seconds, which is not good user experience.

Version-Release number of selected component (if applicable):
tuned-2.3.0

How reproducible:
Always

Steps to Reproduce:
1. tuned-adm profile throughput-performance
2. tuned-adm profile balanced

Actual results:
Up to 10 seconds delay per command

Expected results:
Less delay

Additional info:

Comment 4 Branislav Blaškovič 2013-11-19 10:23:39 UTC
Verified

tuned-2.3.0-3.el7.noarch

:: [   PASS   ] :: Running '/usr/bin/time -f "%E" -o out tuned-adm profile balanced' (Expected 0, got 0)
0:00.88
:: [   PASS   ] :: Running 'cat out' (Expected 0, got 0)
:: [   PASS   ] :: Running 'awk -F':' '{if($2 > 1.5) exit 1;}' out' (Expected 0, got 0)
:: [   PASS   ] :: Running '/usr/bin/time -f "%E" -o out tuned-adm profile balanced' (Expected 0, got 0)
0:00.87
:: [   PASS   ] :: Running 'cat out' (Expected 0, got 0)
:: [   PASS   ] :: Running 'awk -F':' '{if($2 > 1.5) exit 1;}' out' (Expected 0, got 0)
:: [   PASS   ] :: Running '/usr/bin/time -f "%E" -o out tuned-adm profile balanced' (Expected 0, got 0)
0:00.84
:: [   PASS   ] :: Running 'cat out' (Expected 0, got 0)
:: [   PASS   ] :: Running 'awk -F':' '{if($2 > 1.5) exit 1;}' out' (Expected 0, got 0)
:: [   PASS   ] :: Running '/usr/bin/time -f "%E" -o out tuned-adm profile balanced' (Expected 0, got 0)
0:00.84
:: [   PASS   ] :: Running 'cat out' (Expected 0, got 0)
:: [   PASS   ] :: Running 'awk -F':' '{if($2 > 1.5) exit 1;}' out' (Expected 0, got 0)
:: [   PASS   ] :: Running '/usr/bin/time -f "%E" -o out tuned-adm profile balanced' (Expected 0, got 0)
0:00.84
:: [   PASS   ] :: Running 'cat out' (Expected 0, got 0)
:: [   PASS   ] :: Running 'awk -F':' '{if($2 > 1.5) exit 1;}' out' (Expected 0, got 0)

Beaker job is still running. I will provide results soon.

Comment 5 Branislav Blaškovič 2013-11-20 10:07:57 UTC
Beaker job results: https://beaker.engineering.redhat.com/jobs/546885
I've set treshold to 1.5 second. It is under 1 second but I made this decision because beaker machines are pretty unpredictable and we don't want false positives.

Comment 6 Jaroslav Škarvada 2013-11-20 10:41:50 UTC
(In reply to Branislav Blaškovič from comment #5)
> Beaker job results: https://beaker.engineering.redhat.com/jobs/546885
> I've set treshold to 1.5 second. It is under 1 second but I made this
> decision because beaker machines are pretty unpredictable and we don't want
> false positives.

It should be under 1 secs in most "sane" use cases, but e.g. during stress testing the response may take longer. On the other hand the affected tuned can response in up-to 10 seconds, so I think you can safely increase the threshold even more. By issuing e.g. 3 or more profile switch commands and waiting up to e.g. 3 seconds there is high probability that at least one of the commands will timeout with the affected tuned.

Comment 7 Ludek Smid 2014-06-13 11:25:14 UTC
This request was resolved in Red Hat Enterprise Linux 7.0.

Contact your manager or support representative in case you have further questions about the request.