basebuilder_pel7x64builder0
6 years ago
4 changed files with 372 additions and 7 deletions
@ -0,0 +1,100 @@
@@ -0,0 +1,100 @@
|
||||
diff --git a/tuned-gui.glade b/tuned-gui.glade |
||||
index 36e173a..30dd51a 100644 |
||||
--- a/tuned-gui.glade |
||||
+++ b/tuned-gui.glade |
||||
@@ -1,7 +1,6 @@ |
||||
<?xml version="1.0" encoding="UTF-8"?> |
||||
<!-- Generated with glade 3.16.1 --> |
||||
<interface> |
||||
- <requires lib="gtk+" version="3.10"/> |
||||
<object class="GtkAboutDialog" id="aboutdialog1"> |
||||
<property name="can_focus">False</property> |
||||
<property name="type_hint">dialog</property> |
||||
@@ -729,12 +728,6 @@ |
||||
<object class="GtkViewport" id="viewport1"> |
||||
<property name="visible">True</property> |
||||
<property name="can_focus">False</property> |
||||
- <child> |
||||
- <object class="GtkListBox" id="listboxSummaryOfActiveProfile"> |
||||
- <property name="visible">True</property> |
||||
- <property name="can_focus">False</property> |
||||
- </object> |
||||
- </child> |
||||
</object> |
||||
<packing> |
||||
<property name="expand">False</property> |
||||
diff --git a/tuned-gui.py b/tuned-gui.py |
||||
index 8f72fd5..54fd815 100755 |
||||
--- a/tuned-gui.py |
||||
+++ b/tuned-gui.py |
||||
@@ -320,8 +320,6 @@ class Base(object): |
||||
self.label_actual_profile.set_text(self.controller.active_profile()) |
||||
if self.config.get(consts.CFG_RECOMMEND_COMMAND): |
||||
self.label_recommended_profile.set_text(self.controller.recommend_profile()) |
||||
- self.listbox_summary_of_active_profile = \ |
||||
- self.builder.get_object('listboxSummaryOfActiveProfile') |
||||
|
||||
self.data_for_listbox_summary_of_active_profile() |
||||
self.comboboxtext_fast_change_profile.set_model(self.treestore_profiles) |
||||
@@ -446,9 +444,6 @@ class Base(object): |
||||
This method is emited after change profile and on startup of app. |
||||
""" |
||||
|
||||
- for row in self.listbox_summary_of_active_profile: |
||||
- self.listbox_summary_of_active_profile.remove(row) |
||||
- |
||||
if self.is_tuned_connection_ok(): |
||||
self.active_profile = \ |
||||
self.manager.get_profile(self.controller.active_profile()) |
||||
@@ -464,51 +459,6 @@ class Base(object): |
||||
|
||||
self.label_summary_included_profile.set_text('None') |
||||
|
||||
- row = Gtk.ListBoxRow() |
||||
- box = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=0) |
||||
- plugin_name = Gtk.Label() |
||||
- plugin_name.set_markup('<b>Plugin Name</b>') |
||||
- plugin_option = Gtk.Label() |
||||
- plugin_option.set_markup('<b>Plugin Options</b>') |
||||
- box.pack_start(plugin_name, True, True, 0) |
||||
- box.pack_start(plugin_option, True, True, 0) |
||||
- row.add(box) |
||||
- |
||||
- self.listbox_summary_of_active_profile.add(row) |
||||
- |
||||
- sep = Gtk.Separator.new(Gtk.Orientation.HORIZONTAL) |
||||
- self.listbox_summary_of_active_profile.add(sep) |
||||
- sep.show() |
||||
- |
||||
- for u in self.active_profile.units: |
||||
- row = Gtk.ListBoxRow() |
||||
- hbox = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, |
||||
- spacing=0) |
||||
- hbox.set_homogeneous(True) |
||||
- row.add(hbox) |
||||
- label = Gtk.Label() |
||||
- label.set_markup(u) |
||||
- label.set_justify(Gtk.Justification.LEFT) |
||||
- hbox.pack_start(label, False, True, 1) |
||||
- |
||||
- grid = Gtk.Box(orientation=Gtk.Orientation.VERTICAL, |
||||
- spacing=0) |
||||
- grid.set_homogeneous(True) |
||||
- for o in self.active_profile.units[u].options: |
||||
- label_option = Gtk.Label() |
||||
- label_option.set_markup(o + ' = ' + '<b>' |
||||
- + self.active_profile.units[u].options[o] |
||||
- + '</b>') |
||||
- grid.pack_start(label_option, False, True, 0) |
||||
- |
||||
- hbox.pack_start(grid, False, True, 0) |
||||
- self.listbox_summary_of_active_profile.add(row) |
||||
- separator = Gtk.Separator.new(Gtk.Orientation.HORIZONTAL) |
||||
- self.listbox_summary_of_active_profile.add(separator) |
||||
- separator.show() |
||||
- |
||||
- self.listbox_summary_of_active_profile.show_all() |
||||
- |
||||
# def on_treeview_button_press_event(self, treeview, event): |
||||
# popup = Gtk.Menu() |
||||
# popup.append(Gtk.MenuItem('add')) |
@ -0,0 +1,94 @@
@@ -0,0 +1,94 @@
|
||||
From 837c6bd12a5eedc3fbf46291bf1040e724786efd Mon Sep 17 00:00:00 2001 |
||||
From: Marcelo Tosatti <mtosatti@redhat.com> |
||||
Date: Fri, 31 Aug 2018 13:27:12 +0200 |
||||
Subject: [PATCH] start/stop rt-entsk daemon on initialization/shutdown |
||||
MIME-Version: 1.0 |
||||
Content-Type: text/plain; charset=UTF-8 |
||||
Content-Transfer-Encoding: 8bit |
||||
|
||||
The rt-entsk application, part of newer rt-setup packages, |
||||
worksaround a latency issue with static key |
||||
IPI's. What it does it: |
||||
|
||||
/* |
||||
* Open a socket, and enable timestamping on it. |
||||
* |
||||
* This is to avoid Chrony from changing timestamping |
||||
* user count from 0->1 and vice-versa, causing |
||||
* static key enable/disable IPIs. |
||||
* |
||||
*/ |
||||
|
||||
Start/stop the systemctl service from the realtime-virtual-host |
||||
and realtime-virtual-guest profiles. |
||||
|
||||
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com> |
||||
Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com> |
||||
--- |
||||
profiles/realtime-virtual-guest/script.sh | 19 +++++++++++++++++++ |
||||
profiles/realtime-virtual-guest/tuned.conf | 3 +++ |
||||
profiles/realtime-virtual-host/script.sh | 2 ++ |
||||
3 files changed, 24 insertions(+) |
||||
create mode 100755 profiles/realtime-virtual-guest/script.sh |
||||
|
||||
diff --git a/profiles/realtime-virtual-guest/script.sh b/profiles/realtime-virtual-guest/script.sh |
||||
new file mode 100755 |
||||
index 0000000..33cb730 |
||||
--- /dev/null |
||||
+++ b/profiles/realtime-virtual-guest/script.sh |
||||
@@ -0,0 +1,19 @@ |
||||
+#!/bin/sh |
||||
+ |
||||
+. /usr/lib/tuned/functions |
||||
+ |
||||
+start() { |
||||
+ systemctl start rt-entsk |
||||
+ return "$?" |
||||
+} |
||||
+ |
||||
+stop() { |
||||
+ systemctl stop rt-entsk |
||||
+ return "$?" |
||||
+} |
||||
+ |
||||
+verify() { |
||||
+ return "$?" |
||||
+} |
||||
+ |
||||
+process $@ |
||||
diff --git a/profiles/realtime-virtual-guest/tuned.conf b/profiles/realtime-virtual-guest/tuned.conf |
||||
index fb2bc42..8e1f67e 100644 |
||||
--- a/profiles/realtime-virtual-guest/tuned.conf |
||||
+++ b/profiles/realtime-virtual-guest/tuned.conf |
||||
@@ -36,5 +36,8 @@ group.ktimersoftd=0:f:3:*:ktimersoftd.* |
||||
|
||||
ps_blacklist=ksoftirqd.*;rcuc.*;rcub.*;ktimersoftd.* |
||||
|
||||
+[script] |
||||
+script=${i:PROFILE_DIR}/script.sh |
||||
+ |
||||
[bootloader] |
||||
cmdline_rvg=+nohz=on nohz_full=${isolated_cores} rcu_nocbs=${isolated_cores} |
||||
diff --git a/profiles/realtime-virtual-host/script.sh b/profiles/realtime-virtual-host/script.sh |
||||
index 515d254..a9366cb 100755 |
||||
--- a/profiles/realtime-virtual-host/script.sh |
||||
+++ b/profiles/realtime-virtual-host/script.sh |
||||
@@ -87,6 +87,7 @@ start() { |
||||
if [ -f $CACHE_VALUE_FILE ]; then |
||||
echo `cat $CACHE_VALUE_FILE` > $KVM_LAPIC_FILE |
||||
fi |
||||
+ systemctl start rt-entsk |
||||
|
||||
return 0 |
||||
} |
||||
@@ -94,6 +95,7 @@ start() { |
||||
stop() { |
||||
[ "$1" = "full_rollback" ] && teardown_kvm_mod_low_latency |
||||
enable_ksm |
||||
+ systemctl stop rt-entsk |
||||
return "$?" |
||||
} |
||||
|
||||
-- |
||||
2.14.4 |
||||
|
@ -0,0 +1,104 @@
@@ -0,0 +1,104 @@
|
||||
diff --git a/profiles/cpu-partitioning/tuned.conf b/profiles/cpu-partitioning/tuned.conf |
||||
index 3c52215..1821b74 100644 |
||||
--- a/profiles/cpu-partitioning/tuned.conf |
||||
+++ b/profiles/cpu-partitioning/tuned.conf |
||||
@@ -19,13 +19,13 @@ tmpdir=${f:strip:${f:exec:/usr/bin/mktemp:-d}} |
||||
isolated_cores_expanded=${f:cpulist_unpack:${isolated_cores}} |
||||
isolated_cpumask=${f:cpulist2hex:${isolated_cores_expanded}} |
||||
not_isolated_cores_expanded=${f:cpulist_invert:${isolated_cores_expanded}} |
||||
-isolated_cores_present_expanded=${f:cpulist_present:${isolated_cores}} |
||||
-not_isolated_cores_present_expanded=${f:cpulist_present:${not_isolated_cores_expanded}} |
||||
+isolated_cores_online_expanded=${f:cpulist_online:${isolated_cores}} |
||||
+not_isolated_cores_online_expanded=${f:cpulist_online:${not_isolated_cores_expanded}} |
||||
not_isolated_cpumask=${f:cpulist2hex:${not_isolated_cores_expanded}} |
||||
no_balance_cores_expanded=${f:cpulist_unpack:${no_balance_cores}} |
||||
|
||||
-# Fail if isolated_cores contains CPUs which are not present |
||||
-assert2=${f:assertion:isolated_cores contains present CPU(s):${isolated_cores_expanded}:${isolated_cores_present_expanded}} |
||||
+# Fail if isolated_cores contains CPUs which are not online |
||||
+assert2=${f:assertion:isolated_cores contains online CPU(s):${isolated_cores_expanded}:${isolated_cores_online_expanded}} |
||||
|
||||
[sysctl] |
||||
kernel.hung_task_timeout_secs = 600 |
||||
diff --git a/profiles/realtime-virtual-guest/tuned.conf b/profiles/realtime-virtual-guest/tuned.conf |
||||
index b90e76f..fb2bc42 100644 |
||||
--- a/profiles/realtime-virtual-guest/tuned.conf |
||||
+++ b/profiles/realtime-virtual-guest/tuned.conf |
||||
@@ -15,10 +15,10 @@ isolated_cores_assert_check = \\${isolated_cores} |
||||
assert1=${f:assertion_non_equal:isolated_cores are set:${isolated_cores}:${isolated_cores_assert_check}} |
||||
|
||||
isolated_cores_expanded=${f:cpulist_unpack:${isolated_cores}} |
||||
-isolated_cores_present_expanded=${f:cpulist_present:${isolated_cores}} |
||||
+isolated_cores_online_expanded=${f:cpulist_online:${isolated_cores}} |
||||
|
||||
-# Fail if isolated_cores contains CPUs which are not present |
||||
-assert2=${f:assertion:isolated_cores contains present CPU(s):${isolated_cores_expanded}:${isolated_cores_present_expanded}} |
||||
+# Fail if isolated_cores contains CPUs which are not online |
||||
+assert2=${f:assertion:isolated_cores contains online CPU(s):${isolated_cores_expanded}:${isolated_cores_online_expanded}} |
||||
|
||||
[scheduler] |
||||
# group.group_name=rule_priority:scheduler_policy:scheduler_priority:core_affinity_in_hex:process_name_regex |
||||
diff --git a/profiles/realtime-virtual-host/tuned.conf b/profiles/realtime-virtual-host/tuned.conf |
||||
index 0346fff..5e0ff1f 100644 |
||||
--- a/profiles/realtime-virtual-host/tuned.conf |
||||
+++ b/profiles/realtime-virtual-host/tuned.conf |
||||
@@ -20,10 +20,10 @@ isolated_cores_assert_check = \\${isolated_cores} |
||||
assert1=${f:assertion_non_equal:isolated_cores are set:${isolated_cores}:${isolated_cores_assert_check}} |
||||
|
||||
isolated_cores_expanded=${f:cpulist_unpack:${isolated_cores}} |
||||
-isolated_cores_present_expanded=${f:cpulist_present:${isolated_cores}} |
||||
+isolated_cores_online_expanded=${f:cpulist_online:${isolated_cores}} |
||||
|
||||
-# Fail if isolated_cores contains CPUs which are not present |
||||
-assert2=${f:assertion:isolated_cores contains present CPU(s):${isolated_cores_expanded}:${isolated_cores_present_expanded}} |
||||
+# Fail if isolated_cores contains CPUs which are not online |
||||
+assert2=${f:assertion:isolated_cores contains online CPU(s):${isolated_cores_expanded}:${isolated_cores_online_expanded}} |
||||
|
||||
[scheduler] |
||||
# group.group_name=rule_priority:scheduler_policy:scheduler_priority:core_affinity_in_hex:process_name_regex |
||||
diff --git a/profiles/realtime/tuned.conf b/profiles/realtime/tuned.conf |
||||
index b2273cf..c595e67 100644 |
||||
--- a/profiles/realtime/tuned.conf |
||||
+++ b/profiles/realtime/tuned.conf |
||||
@@ -18,10 +18,10 @@ assert1=${f:assertion_non_equal:isolated_cores are set:${isolated_cores}:${isola |
||||
# Non-isolated cores cpumask including offline cores |
||||
not_isolated_cpumask = ${f:cpulist2hex_invert:${isolated_cores}} |
||||
isolated_cores_expanded=${f:cpulist_unpack:${isolated_cores}} |
||||
-isolated_cores_present_expanded=${f:cpulist_present:${isolated_cores}} |
||||
+isolated_cores_online_expanded=${f:cpulist_online:${isolated_cores}} |
||||
|
||||
-# Fail if isolated_cores contains CPUs which are not present |
||||
-assert2=${f:assertion:isolated_cores contains present CPU(s):${isolated_cores_expanded}:${isolated_cores_present_expanded}} |
||||
+# Fail if isolated_cores contains CPUs which are not online |
||||
+assert2=${f:assertion:isolated_cores contains online CPU(s):${isolated_cores_expanded}:${isolated_cores_online_expanded}} |
||||
|
||||
[sysctl] |
||||
kernel.hung_task_timeout_secs = 600 |
||||
diff --git a/tuned/profiles/functions/function_cpulist_invert.py b/tuned/profiles/functions/function_cpulist_invert.py |
||||
index 375eb67..2aff3c9 100644 |
||||
--- a/tuned/profiles/functions/function_cpulist_invert.py |
||||
+++ b/tuned/profiles/functions/function_cpulist_invert.py |
||||
@@ -8,7 +8,7 @@ log = tuned.logs.get() |
||||
class cpulist_invert(base.Function): |
||||
""" |
||||
Inverts list of CPUs (makes its complement). For the complement it |
||||
- gets number of present CPUs from the /sys/devices/system/cpu/present, |
||||
+ gets number of present CPUs from the /sys/devices/system/cpu/online, |
||||
e.g. system with 4 CPUs (0-3), the inversion of list "0,2,3" will be |
||||
"1" |
||||
""" |
||||
diff --git a/tuned/utils/commands.py b/tuned/utils/commands.py |
||||
index 8b7df57..41d6d99 100644 |
||||
--- a/tuned/utils/commands.py |
||||
+++ b/tuned/utils/commands.py |
||||
@@ -363,8 +363,8 @@ class commands: |
||||
# Inverts CPU list (i.e. makes its complement) |
||||
def cpulist_invert(self, l): |
||||
cpus = self.cpulist_unpack(l) |
||||
- present = self.cpulist_unpack(self.read_file("/sys/devices/system/cpu/present")) |
||||
- return list(set(present) - set(cpus)) |
||||
+ online = self.cpulist_unpack(self.read_file("/sys/devices/system/cpu/online")) |
||||
+ return list(set(online) - set(cpus)) |
||||
|
||||
# Converts CPU list to hexadecimal CPU mask |
||||
def cpulist2hex(self, l): |
Loading…
Reference in new issue