First pass : https://github.com/openshift/enterprise/pull/165 I could find no prior art of folks shipping tuned profiles in a unique package but I think this is a good way to do it. RHS folks ship it in their base package, 'redhat-storage-server'. We could do the same perhaps openshift-enterprise-release? With this being a unique package I've gone ahead and added a post scriptlet to switch to the 'openshift-enterprise' profile. If we move this into a more universally installed package we may want to reconsider. I still need to review all the disparate sources of tuning variables, I just wanted to get something working first.
I've moved this work into the origin-server repository and submitted a new PR for that. Once it's merged into origin-server I'll pull it into OSE 2.2. Changes since the first PR : * Moved from an Enterprise specific location into Node RPM SPEC file * Package name changed to tuned-profiles-openshift-node * preun step added to switch the profile back to default Pull Request: https://github.com/openshift/origin-server/pull/6024
Commit pushed to master at https://github.com/openshift/origin-server https://github.com/openshift/origin-server/commit/2e1c1ec89ca93df2ab885cd1603eeb752db4215c Node: create tuned-profiles-openshift-node Bug 889539 - [RFE] create tuned profile for openshift-enterprise nodes This adds an optional subpackage named 'tuned-profiles-openshift-node' which contains a tuned profile suitable for OpenShift Node hosts. When installed this RPM will enable the profile starting tuned if it's not currently running.
tuned-profiles-openshift-node can be installed from openshift_node repo, and it is activated by default. This feature is turned on in automation environment, and I will observe performance status on it. #tuned-adm list Available profiles: - virtual-host - throughput-performance - virtual-guest - default - spindown-disk - latency-performance - laptop-battery-powersave - desktop-powersave - laptop-ac-powersave - server-powersave - openshift-node - enterprise-storage Current active profile: openshift-node
Since there isn't /etc/sysctl.ktune , it is better to comment SYSCTL="/etc/sysctl.ktune by default.
Anping, Ok, I'll comment that out upstream. I've traced the init scripts and unless a user has created /etc/sysctl.ktune on their own I don't believe this would have any adverse effects and I think it's not likely that they've created /etc/sysctl.ktune as it seems RHEL6 versions of tuned have never used that file. -- Scott
Verify this bug with tuned-profiles-openshift-node-0.1.1-2.el6op.x86_64 #SYSCTL="/etc/sysctl.ktune" line is commented out in file ktune.sysconfig. [root@node2 openshift-node]# tuned-adm active Current active profile: openshift-node Service tuned: enabled, running Service ktune: enabled, running No error logs in /var/log/tuned/tuned.log, so move this bug to verified.
Found a new issue when remove tuned-profiles-openshift-node package. # yum erase tuned-profiles-openshift-node Running Transaction Error in PREUN scriptlet in rpm package tuned-profiles-openshift-node /var/tmp/rpm-tmp.v89gEm: line 1: /usr/sbin/tuned-admin: No such file or directory error: %preun(tuned-profiles-openshift-node-0.1.1-2.el6op.x86_64) scriptlet failed, exit status 127 128 packages excluded due to repository priority protections tuned-profiles-openshift-node-0.1.1-2.el6op.x86_64 was supposed to be removed but is not! Verifying : tuned-profiles-openshift-node-0.1.1-2.el6op.x86_64 1/1 Failed: tuned-profiles-openshift-node.x86_64 0:0.1.1-2.el6op Complete! # rpm -q --scripts tuned-profiles-openshift-node.x86_64 postinstall scriptlet (using /bin/sh): /usr/sbin/tuned-adm profile openshift-node preuninstall scriptlet (using /bin/sh): /usr/sbin/tuned-admin profile default # ll /usr/sbin/tuned-admin ls: cannot access /usr/sbin/tuned-admin: No such file or directory Seem like a typo.
The issue in comment 29 is already fixed in 2.2/2015-02-05.3, so move it ON_QA.
Verified this bug with 2.2/2015-02-05.3, and PASS. # rpm -q tuned-profiles-openshift-node.x86_64 tuned-profiles-openshift-node-0.1.2-0.el6op.x86_64 # rpm -q --scripts tuned-profiles-openshift-node.x86_64 postinstall scriptlet (using /bin/sh): /usr/sbin/tuned-adm profile openshift-node > /dev/null 2>&1 preuninstall scriptlet (using /bin/sh): # reset the tuned profile to the recommended profile # $1 = 0 when we're being removed > 0 during upgrades if [ "$1" = 0 ]; then /usr/sbin/tuned-adm profile default > /dev/null 2>&1 fi # yum erase tuned-profiles-openshift-node <--snip--> Running Transaction Erasing : tuned-profiles-openshift-node-0.1.2-0.el6op.x86_64 1/1 80 packages excluded due to repository priority protections Verifying : tuned-profiles-openshift-node-0.1.2-0.el6op.x86_64 1/1 Removed: tuned-profiles-openshift-node.x86_64 0:0.1.2-0.el6op Complete! Remove package successfully.
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://rhn.redhat.com/errata/RHBA-2015-0220.html