1
0
Fork 0
Commit graph

2117 commits

Author SHA1 Message Date
Jaroslav Škarvada
b208ff4d5d
Merge pull request #690 from zacikpa/rpm-ostree-fix
bootloader: Simplify tuning of rpm-ostree kargs
2025-07-23 08:54:38 +02:00
Jaroslav Škarvada
f64c5d1198
Merge pull request #756 from zacikpa/RHEL-79943
functions: Silence errors if module kvm_intel does not exist
2025-07-14 07:28:14 +02:00
Pavol Žáčik
3e05cb783e
bootloader: Remove previously appended rpm-ostree kargs
If TuneD-appended kargs are present and do not match
the kargs to be appended, we should remove them. This
can happen if there was no profile rollback, e.g.,
when using the no-daemon mode.

Resolves: RHEL-86814
2025-05-22 15:13:45 +02:00
Pavol Žáčik
91cb383ad7
bootloader: Simplify tuning of rpm-ostree kargs
The bootloader plugin claims that it does not mess
with existing kernel parameters; make sure we adhere
to that also for rpm-ostree systems:

1. Only append a new karg if the same key=value pair
does not already appear in kernel parameters. If we would
duplicate it, it would not be possible to determine which
one to delete when unapplying the profile.

2. Do not delete existing key=value pairs when the profile
adds a karg with another value for the key. A single key can
appear multiple times in the kernel parameter list with different
values.

Also make sure new kargs are added exactly in the order in which
they appear in the profile. This is especially important for kargs
related to hugepages.

Resolves: RHEL-45836
2025-05-22 15:13:41 +02:00
Jaroslav Škarvada
1c746a35a2
Merge pull request #766 from zacikpa/ncat-fix
beakerlib: Use ncat explicitly instead of nc
2025-05-21 09:18:33 +02:00
Jaroslav Škarvada
b924ccdc75
Merge pull request #772 from RHEmployee/fix-tests-new-lib-api
tests/beakerlib: remove old API call.
2025-05-14 12:35:04 +02:00
Robin Hack
09650925b3 tests/beakerlib: remove old API call.
Library API has been changed downstream and we need
to reflect those changes in upstream.
2025-05-14 05:54:51 -04:00
Jaroslav Škarvada
f828dcf702
Merge pull request #771 from yarda/udev-settle
tuned-main.conf: added startup_udev_settle_wait option
2025-05-07 22:51:59 +02:00
Jaroslav Škarvada
7d061ab06d
tuned-main.conf: added startup_udev_settle_wait option
Timeout in seconds to maximally wait until udev settles. If set to value
bigger than 0, it will either wait until udev settles or the timeout
occurs. Disable with 0.

Resolves: RHEL-88238

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2025-05-07 12:45:01 +02:00
Jaroslav Škarvada
4ce3e0bc49
consts: fixed whitespaces
Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2025-05-07 02:20:06 +02:00
Jaroslav Škarvada
9392599b76
Merge pull request #763 from yarda/udev-remove-race-fix
hotplug: fixed device remove race condition
2025-04-28 11:38:49 +02:00
Pavol Žáčik
8f1c757c87
beakerlib: Use ncat explicitly instead of nc
This is to make sure that we do not use netcat,
which does not work in the unix socket test.
2025-04-15 16:18:18 +02:00
Jaroslav Škarvada
7373cecf3b
hotplug: fixed device remove race condition
During profile loading if the device is assigned to the instance but it
isn't processed yet by the main thread and the remove event fires, TuneD
may try to remove the device from the free list, because it wrongly assumes
that the device is unassigned. With this workaround it shouldn't traceback
in such cases, but there may be still some errors when it tries to tune the
removed device in the main thread. We currently cannot do much about it.

The add/rename udev events should be mostly safe, because there are two
threads - the main thread and the udev callback thread. The udev
callback thread is processing udev events sequentially one by one and it
shouldn't break the main thread data when processing the add/rename
events. It would be better to have one worker thread for it, but it
would require quite a big redesign.

Also the cleanup phase was improved, because now it firstly unsubscribes
the udev events and then it continues with the cleanup which should
minimise problems of udev events firing during the profile unload.

Resolves: RHEL-83827

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2025-04-02 02:43:22 +02:00
Pavol Žáčik
c9f678d8a1
functions: Silence errors if module kvm_intel does not exist
Without the redirect to /dev/null, an error message would
be reported in TuneD logs on aarch64 machines, which do not
have the kernel module.

Resolves: RHEL-79943
2025-03-04 10:06:47 +01:00
Jaroslav Škarvada
889387b000
new release (2.25.1)
Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2025-02-03 20:17:00 +01:00
Jaroslav Škarvada
baadb6dc49
Merge pull request #744 from zacikpa/missing-instance-parameters
plugins: Add missing instance parameters
2025-02-03 12:50:18 +01:00
Pavol Žáčik
6e7794104f
disk: Add missing remove parameter
This one was forgotten in 2f911b7.
2025-02-03 12:30:11 +01:00
Pavol Žáčik
76464d8df1
plugins: Add missing instance parameters
These were all forgotten in 6def0e4.
2025-02-03 12:30:08 +01:00
Jaroslav Škarvada
374697b09f
Merge pull request #737 from zacikpa/functions-fix
Fix races occuring when two threads expand variables at the same time
2025-02-02 20:45:22 +01:00
Jaroslav Škarvada
c624ba6fa4
Merge pull request #741 from SunRed/libexecdir
Makefile: Add support for installation to custom $LIBEXECDIR
2025-02-02 18:13:44 +01:00
Manuel
410344b8db
Makefile: Add support for installation to custom $LIBEXECDIR 2025-02-01 20:50:33 +01:00
Jaroslav Škarvada
a96d7d98e9
Merge pull request #734 from adriaan42/adriaan/scheduler-kthread-switch
plugin_scheduler: add switch to disable processing of kthreads
2025-01-31 23:05:33 +01:00
Jaroslav Škarvada
4b4913f2ce
new release (2.25.0)
Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2025-01-31 21:33:07 +01:00
Adriaan Schmidt
e16400e168 plugin_scheduler: add switch to disable processing of kthreads
Signed-off-by: Adriaan Schmidt <adriaan.schmidt@siemens.com>
2025-01-30 07:19:32 +01:00
Jaroslav Škarvada
08d03e0bf4
Merge pull request #739 from zacikpa/sap-hana-hugepages
sap-hana: Set transparent_hugepages to madvise
2025-01-29 22:43:39 +01:00
Jaroslav Škarvada
54f434e3cf
Merge pull request #738 from ycongal-smile/grub_export
bootloader: export Grub variables to make them available in submenus
2025-01-29 22:43:23 +01:00
Jaroslav Škarvada
8b17fe9d09
Merge pull request #733 from marcan/fix-cpu-online
utils.commands: Fix CPU online detection when not present
2025-01-29 22:34:20 +01:00
Jaroslav Škarvada
5452adada6
Merge pull request #736 from rtzoeller/cqe-mode-rx
plugin_net: handle cqe-mode-rx ethtool option
2025-01-29 22:02:13 +01:00
Jaroslav Škarvada
263f51c8e1
Merge pull request #732 from marcan/fix-cpu-governors
profiles: Correct CPU governor settings
2025-01-29 22:01:26 +01:00
Pavol Žáčik
579cddc7e2
sap-hana: Set transparent_hugepages to madvise
Resolves: RHEL-68454
2025-01-29 13:26:15 +01:00
Yoann Congal
e9f0f228b3 bootloader: export Grub variables to make them available in submenus
Without exporting the grub variables, they are only available in the
main grub menu[0]. When descending in a submenu (like in default Debian for
example), tuned_* variable are expanded to the empty string and, so,
tuned kernel cmdline tuning is effectively disabled.

With the export, variables are available in submenus and tuned tuning is
applied as expected.

[0]: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1094201#10

Signed-off-by: Yoann Congal <yoann.congal@smile.fr>
2025-01-27 11:59:21 +01:00
Pavol Žáčik
64166c5f5e
functions: Create a new parser object for each string expansion
Previously, the parser state would be shared, creating races
when two threads would attempt to expand functions in strings
at the same time (e.g., when a device was hotplugged during
TuneD initialization).

The change requires minor refactoring: the function `Repository`
class is now the one providing the expansion API to the `Variables`
class instead of the original `Functions` class (now renamed to
`Parser` and newly created for each expansion).

Resolves: RHEL-75773
2025-01-23 09:40:54 +01:00
Pavol Žáčik
f4c52cd05b
utils: Rename PluginLoader to ClassLoader
The `PluginLoader` class is used as an interace implemented by
all kinds of repositories: of profile plugins, functions, monitors.
While these are all technically "plug-in", the naming is confusing.

The commit also updates the `load_all_plugins` method of the class
(now `load_all_classes`) to use the class loader parameters
(prefix, namespace) instead of hardcoded ones.
2025-01-23 09:40:29 +01:00
Ryan Zoeller
cbaec70ad9 plugin_net: handle cqe-mode-rx ethtool option
Parsing ethtool output has been broken for several years, since `ethtool -c`
started producing a line resembling `CQE mode RX: n/a  TX: n/a`.
This prevents setting any [net] coalesce= options, which log
`tuned.plugins.plugin_net: unknown coalesce parameter(s): {'CQE mode RX'}`.

Substituting `cqe-mode-rx:` for `CQE mode RX:` resolves the issue,
although there is a conflict with the `adaptive-tx` workaround
which prevents us from supporting `cqe-mode-tx` directly.
Do not attempt to address that issue as part of this change.

Fixes #726.

Signed-off-by: Ryan Zoeller <ryan.zoeller@aliaro.com>
2025-01-22 15:37:00 -06:00
Hector Martin
e24bfef651 profiles: Correct CPU governor settings
First, always prefer schedutil for balanced/powersave. On platforms
where this governor is available, this enables Energy-Aware-Scheduling
which offers the best power efficiency and performance combination.
There is absolutely no reason to use another governor by default in the
"balanced" profile on these systems, in particular.

Second, swap around "conservative" and "ondemand". "conservative" is
supposed to be lower power and higher latency. The commit that made this
change [1] tested on a single server platform (10 years ago), but came
to the wrong conclusion. Dividing the throughput by power numbers of
that commit, "conservative" did in fact provide better performance/watt,
which is the intent of lower-power modes. The fact that it also
happened to provide better overall performance than "ondemand" is
probably an artifact of suboptimal power-management behavior or a
flawed test.

[1] b2897d9c1c

Signed-off-by: Hector Martin <marcan@marcan.st>
2025-01-21 08:31:13 +09:00
Hector Martin
13dc68447d utils.commands: Fix CPU online detection when not present
Not all platforms can offline CPUs. On those that can't, there is no
"online" attribute. Default to online in that case.

Signed-off-by: Hector Martin <marcan@marcan.st>
2025-01-21 08:15:39 +09:00
Jaroslav Škarvada
7480983aed
new release (2.25.0-rc.1)
Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2025-01-19 18:48:14 +01:00
Jaroslav Škarvada
b36960bce3
Merge pull request #730 from yarda/RHEL-60906-fix-scheduler
plugin_scheduler: fixed API
2025-01-19 17:42:33 +01:00
Jaroslav Škarvada
300444b236
docs: fixed docs generation on centos-7
Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2025-01-18 22:48:44 +01:00
Jaroslav Škarvada
42c3837f40
plugin_scheduler: fixed API
It's fixing hidden conflict caused by #725 and #728 which were merged
without rebase.

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2025-01-18 20:45:30 +01:00
Jaroslav Škarvada
40588f60e8
Merge pull request #729 from yarda/bin-sbin-merge-fix
makefile: added support for installation to custom $BINDIR/$SBINDIR
2025-01-18 19:58:43 +01:00
Jaroslav Škarvada
0f1e4a45a2
Merge pull request #728 from yarda/RHEL-60906
plugin_net: added support for hotplug and rename
2025-01-18 19:58:18 +01:00
Jaroslav Škarvada
0b82ce0c9b
Merge pull request #727 from zacikpa/hold-clearing-fix
tuned-ppd: Fix handling of profile change signals from TuneD
2025-01-18 19:56:04 +01:00
Jaroslav Škarvada
dee3b407c6
Merge pull request #718 from yarda/rhel_enable_docs
doc: enable documentation generation on RHEL with asciidoc
2025-01-18 19:55:00 +01:00
Jaroslav Škarvada
e264ee1fac
Merge pull request #716 from yarda/perf-optional
plugin_scheduler: make perf support optional
2025-01-18 19:54:34 +01:00
Jaroslav Škarvada
2a1bb41220
Merge pull request #717 from zacikpa/affinity-error-logs
scheduler: Log process info when its affinity cannot be changed and re-check blacklisted cgroups
2025-01-18 19:52:34 +01:00
Jaroslav Škarvada
13dfc68b85
Merge pull request #725 from yarda/scheduler-tunables-changes
scheduler: updated sched knobs for kernels 6.6+
2025-01-16 22:24:37 +01:00
Jaroslav Škarvada
edee85a35f
Merge pull request #700 from lack/lenient_kvm_script
Do not initialize kvm low latency if kvm not present
2025-01-16 22:14:00 +01:00
Jaroslav Škarvada
b8392f9932
Merge pull request #715 from ruihe774/raw_epp
plugin_cpu: allow raw energy_performance_preference values
2025-01-16 22:08:18 +01:00
Jaroslav Škarvada
9535b07cbe plugin_scheduler: make perf support optional
Requested in: https://src.fedoraproject.org/rpms/tuned/pull-request/8

Signed-off-by: Jaroslav Škarvada <jskarvad@redhat.com>
2025-01-16 21:57:41 +01:00