From c46acdcb5f38691c622a5c0849ac07f8fec62d014135768bacc3b590bd70ed3e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adrian=20Schr=C3=B6ter?= Date: Thu, 20 Feb 2025 10:08:11 +0100 Subject: [PATCH] Sync from SUSE:SLFO:Main tuned revision 7f4f4bd9ca380f9a7f40b081710f2592 --- ...uned-consts-Fix-grub.cfg-path-in-SLE.patch | 27 ++ _service | 12 +- _servicedata | 2 +- tuned-2.20.0.18+git.7b1a20b.obscpio | 3 - tuned-2.25.1.0+git.889387b.obscpio | 3 + tuned.changes | 300 +++++++++++++++++- tuned.obsinfo | 6 +- tuned.rpmlintrc | 2 +- tuned.spec | 113 +++++-- 9 files changed, 428 insertions(+), 40 deletions(-) create mode 100644 0001-tuned-consts-Fix-grub.cfg-path-in-SLE.patch delete mode 100644 tuned-2.20.0.18+git.7b1a20b.obscpio create mode 100644 tuned-2.25.1.0+git.889387b.obscpio diff --git a/0001-tuned-consts-Fix-grub.cfg-path-in-SLE.patch b/0001-tuned-consts-Fix-grub.cfg-path-in-SLE.patch new file mode 100644 index 0000000..6ca55ea --- /dev/null +++ b/0001-tuned-consts-Fix-grub.cfg-path-in-SLE.patch @@ -0,0 +1,27 @@ +From e5f4a3bb82eb64081af16c49d68260233c55396c Mon Sep 17 00:00:00 2001 +From: Gabriel Krisman Bertazi +Date: Mon, 27 Jan 2025 16:08:22 -0500 +Subject: [PATCH] tuned/consts: Fix grub.cfg path in SLE + +Out of tree patch. Tuned hardcodes the grub.cfg path to a Red +Hat-specific symlink. Replace it with the direct /boot path. +--- + tuned/consts.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tuned/consts.py b/tuned/consts.py +index 4606aee..63ca10f 100644 +--- a/tuned/consts.py ++++ b/tuned/consts.py +@@ -31,7 +31,7 @@ ERROR_THRESHOLD = 3 + + # bootloader plugin configuration + BOOT_DIR = "/boot" +-GRUB2_CFG_FILES = ["/etc/grub2.cfg", "/etc/grub2-efi.cfg"] ++GRUB2_CFG_FILES = ["/boot/grub2/grub.cfg", "/etc/grub2-efi.cfg", ] + GRUB2_CFG_DIR = "/etc/grub.d" + GRUB2_TUNED_TEMPLATE_NAME = "00_tuned" + GRUB2_TUNED_TEMPLATE_PATH = GRUB2_CFG_DIR + "/" + GRUB2_TUNED_TEMPLATE_NAME +-- +2.47.0 + diff --git a/_service b/_service index 6ec23b9..4e39ff6 100644 --- a/_service +++ b/_service @@ -1,17 +1,19 @@ - + git https://github.com/redhat-performance/tuned + @PARENT_TAG@.@TAG_OFFSET@+git.%h v(.*) enable - + xz diff --git a/_servicedata b/_servicedata index 070c09f..d114853 100644 --- a/_servicedata +++ b/_servicedata @@ -1,4 +1,4 @@ https://github.com/redhat-performance/tuned - 7b1a20b64c28f75528328a242f49e9bcaed1e857 \ No newline at end of file + 889387b0001b783514523162de21af406e31a549 \ No newline at end of file diff --git a/tuned-2.20.0.18+git.7b1a20b.obscpio b/tuned-2.20.0.18+git.7b1a20b.obscpio deleted file mode 100644 index d305e46..0000000 --- a/tuned-2.20.0.18+git.7b1a20b.obscpio +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:aace63527966abd2c2a42a62209ab5b376d585ff301a304ae4882e3fdb29e4c7 -size 1053196 diff --git a/tuned-2.25.1.0+git.889387b.obscpio b/tuned-2.25.1.0+git.889387b.obscpio new file mode 100644 index 0000000..2e5be18 --- /dev/null +++ b/tuned-2.25.1.0+git.889387b.obscpio @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:06e2385a33c0c06f4153351cee92be0b255c5b90fb32787117b0591eb646a887 +size 1178636 diff --git a/tuned.changes b/tuned.changes index 72a49cd..66ed2c9 100644 --- a/tuned.changes +++ b/tuned.changes @@ -1,8 +1,306 @@ ------------------------------------------------------------------- -Mon Dec 04 11:46:46 CET 2023 - aschnell@suse.com +Tue Feb 04 10:43:48 UTC 2025 - trenn@suse.de + +- Add LIBEXECDIR=%{_prefix}/lib to adopt libexecdir and remove + the sed hack in spec due to mainline git 410344b8dbc64bada45be +- Update to version 2.25.1.0+git.889387b: + * new release (2.25.1) + * disk: Add missing remove parameter + * plugins: Add missing instance parameters + * Makefile: Add support for installation to custom $LIBEXECDIR + * new release (2.25.0) + * plugin_scheduler: add switch to disable processing of kthreads + * sap-hana: Set transparent_hugepages to madvise + * bootloader: export Grub variables to make them available in submenus + * functions: Create a new parser object for each string expansion + * utils: Rename `PluginLoader` to `ClassLoader` + * plugin_net: handle cqe-mode-rx ethtool option + * profiles: Correct CPU governor settings + * utils.commands: Fix CPU online detection when not present + * new release (2.25.0-rc.1) + * docs: fixed docs generation on centos-7 + * plugin_scheduler: fixed API + * plugin_scheduler: make perf support optional + * plugin_net: added support for hotplug and rename + * scheduler: Postpone cgroup blacklist check and double-check after fail + * makefile: added support for installation to custom $BINDIR/$SBINDIR + * tuned-ppd: Do not always clear holds with TuneD profile change signal + * tuned-ppd: Check that TuneD profile change signal is relevant + * doc: enable documentation generation on RHEL with asciidoc + * scheduler: Log process info when its affinity cannot be changed + +------------------------------------------------------------------- +Mon Jan 27 21:33:57 UTC 2025 - Gabriel Krisman Bertazi + +- Fix grub.cfg path (bsc#1236491) +A 0001-tuned-consts-Fix-grub.cfg-path-in-SLE.patch + +------------------------------------------------------------------- +Wed Jan 22 15:27:18 UTC 2025 - Dominique Leuenberger + +- Drop rcFOO symlinks for CODE16 (PED-266). + +------------------------------------------------------------------- +Fri Jan 17 07:21:34 UTC 2025 - trenn@suse.de + +- Update to version 2.24.1.50+git.13dfc68: + * scheduler: updated sched knobs for kernels 6.6+ + * plugin_cpu: allow raw energy_performance_preference values + * Do not initialize kvm low latency if kvm not present +- Do not conflict with power-profiles-daemon, this is managed via + ppd-service in the tuned-ppd subpackage (bsc#1234754) + +------------------------------------------------------------------- +Thu Jan 16 08:31:46 UTC 2025 - trenn@suse.de + +- Update to version 2.24.1.44+git.cc168b9: + * tuned-ppd: Remove the use of StrEnum + * tuned-ppd: Disallow releasing profile holds of other processes + * tuned-ppd: Unify polkit policy with power-profiles-daemon + * Obsolete power-profiles-daemon + * Document new vm plugin options + * Adjust profiles to set dirty_(bytes|ratio) via the vm plugin + * vm: Add support for dirty_(bytes|ratio) sysctl parameters + * tuned-ppd: Support the new UPower PPD namespace + * tuned-ppd: Enable changing profile via function keys + * tuned-ppd: Use inotify to check for performance degradation + * tuned-ppd: Require the presence of the balanced profile + * tuned-ppd: Add the version property + * tuned-ppd: Add docstrings + * tuned-ppd: Keep track of active and base profile + * tuned-ppd: Fix UPower signal handler initialization + * Add variables to BLS entries only if grub is used + * powertop2tuned: use default user profile path from the consts + * tuned-ppd: Use effective hold profile when adding profile holds + * Bump doc/manual revision date and number + * Clean up plugin docstrings + * Add a script for generation of plugin docs from docstrings + * scheduler: Do not assume that perf events have type attribute + * Fix the error in the raise statement of check_positive() + * fix: expand variables in Plugin._verify_all_device_commands + * Allow shared service drop-in directory + * drop support for cpuspeed + * Parse no_turbo cpu plugin option using commands.get_bool + +------------------------------------------------------------------- +Tue Dec 17 19:11:54 UTC 2024 - Mel Gorman + +- Move gobject dependency to gtk package as it is the only utility that + imports gi. + +------------------------------------------------------------------- +Tue Dec 17 17:52:42 UTC 2024 - Mel Gorman + +- Remove unnecessary cpupower dependency, sysfs fallback is used instead. + +------------------------------------------------------------------- +Thu Nov 28 16:27:49 UTC 2024 - trenn@suse.de + +- Fix below security issues found by SUSE security review of latest + polkit API additions. Kudos go to Matthias Gerstner (bsc#1232412) +- fixed privileged execution of arbitrary scripts by active local user + resolves: CVE-2024-52336 +- added sanity checks for API methods parameters + resolves: CVE-2024-52337 +- Update to version 2.24.1.0+git.90c24ee: + * new release (2.24.1) + * spec: used macro for profiles path and other fixes + * realtime: remove leftover use of tuna + +------------------------------------------------------------------- +Sat Oct 26 12:45:09 UTC 2024 - Thomas Renninger + +- Correct service cleanup calls in preun and postun scripts +- Move tmpfile_create before service_add_post +- Added python3-pyudev and python3-dbus-python as BuildRequires + for added check section +- Move user defined profiles + from /etc/tuned/ + into subdirs /etc/tuned/PROFILE + via spec's %post routine +- Enable make test in check section +- Update has at least parts of jsc#PED-10695 + +------------------------------------------------------------------- +Sun Aug 25 17:28:21 UTC 2024 - pallaswept@proton.me + +- Migrate profiles to /etc/tuned/profiles/ and /usr/lib/tuned/profiles/ + * Per upstream #615 and #609 + +- Update to version 2.24.0.2+git.c082797: + * controller init: set _on_battery before switching profile + +- New release (2.24.0) + * Clear plugin repository when stopping tuning + * man: add description of the balanced-battery profile + +- New release (2.24.0-rc.1) + * chore: remove dead irqbalance functions + * plugin_irqbalance: switch to IRQBALANCE_BANNED_CPULIST + * hotplug: wait for device initialization + * Add `functions` to the files copied by the release-cp Makefile target + * Add package2cpus and packages2uncores matcher functions + * uncore: Allow to configure frequency limits using percent + * plugin_scheduler: Adjust error logging in _set_affinity + * fix: expand variables in plugin_irq + * tests: Restore TuneD service after the error messages test + * tests: Do not run tunedDisableSystemdRateLimitingStart via rlRun + * Enable controller reset for audio by default + * tuned-ppd: Adjust log message emitted when battery status changes + * tuned-ppd: Refactor daemon initialization + * tuned-ppd: Remove magic constant "unknown" + * Add support for controlling amd-pstate core performance boost + * spec: Start tuned-ppd right away if swapping from active PPD + * spec: Add standard systemd scriptlet macros for tuned-ppd + * tuned-ppd: Remove PIDFile from the systemd service file + * tuned-ppd: Add an option to log to a file + * Install script functions and recommend.d to /usr/lib/tuned/ + * Rename TUNED_PROFILESDIR to TUNED_PROFILES_DIR + * CNF-13015: Fix helper function not accessing the correct return result + * CNF-13015: Add helper function to run `lscpu` and parse result using regex + parameters - This is similar to the cpuinfo function that reads from + /proc/cpuinfo - Unfortunately that function was insufficient for our needs + as we need to identify both the Vendor and Architecture reliably + +------------------------------------------------------------------- +Sat Jun 22 15:29:45 UTC 2024 - tobi.goergens@gmail.com + +- Update to version 2.23.0.2+git.5d5dbfc: + * chore: remove use of deprecated Logger.warn() + * new release (2.23.0) + * Disk plugin: make hdparm device checks lazy + * Revert "Video plugin: make hdparm device checks lazy" + * Video plugin: make hdparm device checks lazy + * Do not check for x86_energy_perf_policy if it won't be used + * Check that writes are necessary if they may cause redundant IPIs + * Add an option to skip `write_to_file` if the content would not change + * Turn on amdgpu panel power savings in balanced-battery + * Modify the video plugin for tuning of the amdgpu `panel_power_savings` attribute + * video: Don't show error when trying to read radeon files + * video: make missing radeon_powersave files quieter + * video: Rename _radeon_powersave_files to _files + * feat: add plugin_irq + * throughput-performance: dropped unused AMD related variable + * ppd: Adjust the detection of 'performance-degraded' + * ppd: Fix hold releasing + * ppd: Add debug logs when changing base profile + * Re-check dbus when (re)starting TuneD from tuned-adm profile + * functions: added 'log' which helps with debugging + * Simplify reading/writing from/to sysctl by using existing functions + * Fix logs in `commands.read_file` + * plugin_cpu: decrease the severity of _has_pm_qos==False + * sap-netweaver: increased vm.max_map_count + * daemon: buffer sighup signal + * tuned-ppd: Detect battery change events + * Migrate profiles to /etc/tuned/profiles/ and /usr/lib/tuned/profiles/ + * Propagate unexpected exceptions in the wait exception handler + * Add an option to configure profile directories + * Use get_list to parse unix_socket_signal_path + * Add a function to parse lists in the global configuration + * Added intel_recommended_pstate builtin function. + * dbus: add commands to dynamically create/destroy instances + * dbus: ensure that hotplug operations only work on hotplug plugins + * instance: add priority as a property + * monitor_net: fixed traceback if stats cannot be read + * plugin_net: do not read monitors if dynamic tuning is disabled + * Allow equal characters in parameter value + +------------------------------------------------------------------- +Thu Feb 29 11:37:09 UTC 2024 - trenn@suse.de + +- Update to version 2.22.1.2+git.86ac977: + * fix-error + * new release (2.22.1) + * Rename plugin_intel_uncore.py to plugin_uncore.py + * Rename IntelUncorePlugin to UncorePlugin + * network-throughput: increased net.ipv4.tcp_rmem default value + * spec: cleanup, drop RHEL dynamic_tuning customization + * new release (2.22.0) +- Polkit changes got accepted by security review (bsc#1220081) + +------------------------------------------------------------------- +Fri Feb 16 13:30:06 UTC 2024 - trenn@suse.de + +- Update to version 2.22.0.rc.1.0+git.ad314ee: + * Disable dynamic tuning by default + * plugin_cpu: improved backward compat. of the pm_qos parser warnings + +------------------------------------------------------------------- +Sun Feb 11 18:29:24 UTC 2024 - trenn@suse.de + +- Update to version 2.22.0-rc.1.0+git.ad314ee: + * new release (2.22.0-rc.1) + * Add missing install command for tuned-ppd.py + * Fixes for intel uncore plugin + * Add intel uncore plugin + * scheduler: add option for ignoring IRQs affinity + * Configure the PPD-to-TuneD daemon to work as a replacement of PPD + * Implement the PPD-to-TuneD daemon + * Make DBusExporter reusable for other services + * Do not report errors on systems with no wifi + * Add an ACPI plugin + * plugin_cpu: Support cstate settings of `pm_qos_resume_latency_us` + * Skip calling rpm-ostree kargs in no-op case + * Expand sysctl plugin options when reporting overrides + * profiles: add energy_performance_preference hints to profiles + * hotplug: do not report ENOENT errors on device remove + * profiles: Improve 'isolated_cores=' help text + * Be explicit about amd-pstate support + * Fixed REs escape sequences not to trigger SyntaxWarning + * sap-hana-kvm-guest: fix whitespaces + * Fix TextView to expand with window + +------------------------------------------------------------------- + +Mon Dec 04 11:28:35 CET 2023 - aschnell@suse.com - do not package inoperable plugins (bsc#1217758) +------------------------------------------------------------------- + +Wed Nov 15 09:42:09 UTC 2023 - trenn@suse.de + +- Update to version 2.21.0.17+git.5d3b469: + * Add API functions to retrieve active instances and their devices + * Add a tuned-adm command for moving devices between plugin instances + * Add support for sysctl names with slash + * Make all functions in plugin_sysctl.py methods of SysctlPlugin + * RHEL-3689: Print all arguments of failing command in err_msg + * style: fix inconsistent whitespace in plugin_cpu.py + * Return 0 when ksm services do not exist + * fix error + * Converted SPEC file license to SPDX + +------------------------------------------------------------------- + +Fri Sep 15 15:27:32 UTC 2023 - trenn@suse.de + +- Update to version 2.21.0.0+git.670541d: + * new release (2.21.0) + * api: fixed stop method not to require any parameter + * new release (2.21.0-rc.1) + * gui: multiple fixes and warnings removal + * gui: fixed inconsistent tabs and spaces, introduced by #516 + * Serialize SIGHUP processing + * No errors when physical_package_id file does not exist + * Update tests: disable systemd rate limiting. + * network-latency: enable rcu_normal_after_boot=1 kernel parameter + * remove ktimer_lockless_check sysfs setting from realtime-virtual profiles + * move rtentsk to network-latency profile + * move "tsc=reliable" setting from realtime to network-latency tuned configuration + * unify common sysctl settings between realtime and cpu-partitioning profiles + * Rename rollback-related constants and variables + * Add rollback option to tuned-main.conf + * Recast README into MarkDown with various minor corrections and improvements + * Remove setting ip forwarding via openshift profile + * Fix logging in [scheduler] plug-in + * fixed sap-hana docu regarding processor power settings + * Added sap-hana-kvm-guest profile + * tests/beakerlib: Add new test which covers socket API. + * plugin_net: expand variables properly + * fix typo + * add error dialog when no active profile set + ------------------------------------------------------------------- Fri Apr 14 13:12:27 UTC 2023 - trenn@suse.de diff --git a/tuned.obsinfo b/tuned.obsinfo index ec871b2..09882cf 100644 --- a/tuned.obsinfo +++ b/tuned.obsinfo @@ -1,4 +1,4 @@ name: tuned -version: 2.20.0.18+git.7b1a20b -mtime: 1680015467 -commit: 7b1a20b64c28f75528328a242f49e9bcaed1e857 +version: 2.25.1.0+git.889387b +mtime: 1738610220 +commit: 889387b0001b783514523162de21af406e31a549 diff --git a/tuned.rpmlintrc b/tuned.rpmlintrc index 79298ed..860f5eb 100644 --- a/tuned.rpmlintrc +++ b/tuned.rpmlintrc @@ -1,4 +1,4 @@ -addFilter("W: files-duplicate /etc/tuned/realtime-virtual-host-variables.conf /etc/tuned/realtime-virtual-guest-variables.conf") addFilter("E: zero-length /etc/tuned/active_profile") addFilter("E: zero-length /etc/tuned/profile_mode") addFilter("E: zero-length /etc/tuned/post_loaded_profile") +addFilter("E: zero-length /etc/tuned/ppd_base_profile") diff --git a/tuned.spec b/tuned.spec index c5f3a29..6e58b00 100644 --- a/tuned.spec +++ b/tuned.spec @@ -1,7 +1,7 @@ # # spec file for package tuned # -# Copyright (c) 2023 SUSE LLC +# Copyright (c) 2025 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,9 +16,10 @@ # -%define profile_dir %{_prefix}/lib/%{name} +%define system_dir %{_prefix}/lib/%{name}/ +%define profile_dir %{system_dir}profiles/ Name: tuned -Version: 2.20.0.18+git.7b1a20b +Version: 2.25.1.0+git.889387b Release: 0 Summary: A dynamic adaptive system tuning daemon License: GPL-2.0-or-later @@ -29,13 +30,16 @@ Source1: tuned.rpmlintrc # PATCH-FIX-OPENSUSE fix-allow-receive_sender-default.patch allow receive_* is normally # not needed as that is the default -- Patch0: fix-allow-receive_sender-default.patch +Patch1: 0001-tuned-consts-Fix-grub.cfg-path-in-SLE.patch BuildRequires: bash-completion BuildRequires: desktop-file-utils BuildRequires: pkgconfig BuildRequires: python3-base +BuildRequires: python3-dbus-python +# needed by check section +BuildRequires: python3-pyudev BuildRequires: pkgconfig(systemd) # need perf_bias now -Requires: cpupower >= 4.19 Requires: ethtool Requires: gawk Requires: hdparm @@ -43,11 +47,13 @@ Requires: polkit Requires: python3-configobj Requires: python3-dbus-python Requires: python3-decorator -Requires: python3-gobject Requires: python3-linux-procfs +Requires: python3-pyinotify Requires: python3-pyudev Requires: util-linux Requires: virt-what +Conflicts: laptop-mode-tools +Conflicts: tlp BuildArch: noarch %{?systemd_requires} @@ -86,6 +92,7 @@ Summary: Disk and net statistic monitoring systemtap scripts - GTK GUI Group: System/Base Requires: %{name} = %{version} Requires: powertop +Requires: python3-gobject %description gtk GTK GUI that can control tuned and provide simple profile editor. @@ -166,18 +173,29 @@ Requires: %{name} = %{version} %description profiles-spectrumscale Additional tuned profile(s) optimized for IBM Spectrum Scale. +%package ppd +Summary: PPD compatibility daemon +Requires: %{name} = %{version} +Conflicts: ppd-service +# The compatibility daemon is swappable for power-profiles-daemon +Provides: ppd-service + +%description ppd +An API translation daemon that allows applications to easily transition +to TuneD from power-profiles-daemon (PPD). + %prep %autosetup -p1 %build # The tuned daemon is written in pure Python. Nothing requires to be built. # Just a hack to avoid installation in a wrong directory -sed -i 's|usr/libexec/tuned|%{profile_dir}|' Makefile sed -i 's|$(SYSCONFDIR)/modprobe.d|%{_modprobedir}|' Makefile sed -i 's|$(SYSCONFDIR)/dbus-1/system.d|%{_datadir}/dbus-1/system.d|' Makefile %install -%make_install TUNED_PROFILESDIR=%{profile_dir} +%make_install LIBEXECDIR=%{_prefix}/lib TUNED_PROFILES_DIR=%{profile_dir} +make install-ppd DESTDIR=%{buildroot} TUNED_PROFILES_DIR=%{profile_dir} # we do not have the python perf module (see bsc #1217758) rm %{buildroot}/%{python3_sitelib}/tuned/plugins/plugin_{scheduler,irqbalance}.py %py3_compile %{buildroot}/%{python3_sitelib} @@ -185,25 +203,43 @@ rm -rf %{buildroot}/%{_datadir}/doc # Remove unwanted stuff instead of excluding them in files list rm -rf %{buildroot}%{profile_dir}/{default,desktop-powersave,laptop-ac-powersave,server-powersave,laptop-battery-powersave,enterprise-storage,spindown-disk} rm %{buildroot}%{_mandir}/man7/tuned-profiles-compat.7 +%if 0%{?suse_version} < 1600 ln -sf service %{buildroot}%{_sbindir}/rctuned +%endif %if 0%{?sle_version} && %{?suse_version} < 1599 -rm -r %{buildroot}%{_prefix}/lib/tuned/sap-netweaver -rm -r %{buildroot}%{_prefix}/lib/tuned/sap-hana +rm -r %{buildroot}%{profile_dir}/sap-netweaver +rm -r %{buildroot}%{profile_dir}/sap-hana rm %{buildroot}%{_mandir}/man7/tuned-profiles-sap.7 rm %{buildroot}%{_mandir}/man7/tuned-profiles-sap-hana.7 %endif +%check +make test PYTHON=python3 + %post -%service_add_post %{name}.service -%tmpfiles_create %{_tmpfilesdir}/%{name}.conf +%tmpfiles_create %{name}.conf +%systemd_post %{name}.service + +# migrate all user-defined profiles from /etc/tuned/ to /etc/tuned/profiles/ +for f in %{_sysconfdir}/tuned/*; do + if [ -e "$f/tuned.conf" ]; then + mv -n "$f" %{_sysconfdir}/tuned/profiles/ + fi +done + +%post ppd +%systemd_post %{name}-ppd.service %pre -%service_add_pre %{name}.service +%systemd_pre %{name}.service # Avoid restoring outdated stuff in posttrans [ ! -f "%{_sysconfdir}/modprobe.d/tuned.conf.rpmsave" ] || \ mv -f "%{_sysconfdir}/modprobe.d/tuned.conf.rpmsave" "%{_sysconfdir}/modprobe.d/tuned.conf.rpmsave.old" || : +%pre ppd +%systemd_pre %{name}-ppd.service + %posttrans # Migration of modprobe.conf files to _modprobedir [ ! -f "%{_sysconfdir}/modprobe.d/tuned.conf.rpmsave" ] || \ @@ -212,39 +248,50 @@ rm %{buildroot}%{_mandir}/man7/tuned-profiles-sap-hana.7 %preun %service_del_preun %{name}.service +%preun ppd +%service_del_preun %{name}-ppd.service + %postun %service_del_postun %{name}.service +%postun ppd +%service_del_postun %{name}-ppd.service + %files %license COPYING -%doc AUTHORS README +%doc AUTHORS README.md %{_datadir}/bash-completion/completions/tuned-adm %{_datadir}/polkit-1/actions/com.redhat.tuned.policy %{python3_sitelib}/tuned %{_sbindir}/tuned %{_sbindir}/tuned-adm +%if 0%{?suse_version} < 1600 %{_sbindir}/rctuned -%dir %{profile_dir} -%dir %{profile_dir}/recommend.d +%endif +%dir %{system_dir} +%dir %{system_dir}/recommend.d %exclude %{python3_sitelib}/tuned/gtk # General files -%{profile_dir}/pmqos-static.py -%{profile_dir}/functions -%{profile_dir}/recommend.d/50-tuned.conf -%{profile_dir}/defirqaffinity.py +%{system_dir}/pmqos-static.py +%{system_dir}/functions +%{system_dir}/recommend.d/50-tuned.conf +%{system_dir}/defirqaffinity.py %if 0%{?sle_version} && %{?suse_version} < 1599 -%exclude %{_prefix}/lib/tuned/sap-netweaver -%exclude %{_prefix}/lib/tuned/sap-hana +%exclude %{profile_dir}/sap-netweaver +%exclude %{profile_dir}/sap-hana +%exclude %{profile_dir}/sap-hana-kvm-guest %exclude %{_mandir}/man7/tuned-profiles-sap.7%{?ext_man} %exclude %{_mandir}/man7/tuned-profiles-sap-hana.7%{?ext_man} %endif # Profiles included in main package - alphabetically sorted +%dir %{profile_dir} %{profile_dir}/accelerator-performance %{profile_dir}/aws %{profile_dir}/balanced +%{profile_dir}/balanced-battery %{profile_dir}/cpu-partitioning %{profile_dir}/cpu-partitioning-powersave %{profile_dir}/desktop @@ -262,15 +309,17 @@ rm %{buildroot}%{_mandir}/man7/tuned-profiles-sap-hana.7 # active_profile might be empty when built via build service, but typically # not on a real install -> better do not mark it %%ghost -%config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/tuned/active_profile +%config(noreplace) %{_sysconfdir}/tuned/active_profile +%config(noreplace) %{_sysconfdir}/tuned/ppd_base_profile %config(noreplace) %{_sysconfdir}/tuned/cpu-partitioning-variables.conf %config(noreplace) %{_sysconfdir}/tuned/cpu-partitioning-powersave-variables.conf %config(noreplace) %{_sysconfdir}/tuned/tuned-main.conf %config(noreplace) %{_sysconfdir}/tuned/profile_mode +%config(noreplace) %{_sysconfdir}/tuned/profiles %config(noreplace) %{_sysconfdir}/tuned/post_loaded_profile %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/tuned/bootcmdline -%{_sysconfdir}/grub.d -%{_tmpfilesdir}/tuned.conf +%config %{_sysconfdir}/grub.d +%{_tmpfilesdir}/%{name}.conf %{_unitdir}/tuned.service %{_modprobedir}/tuned.conf %{_datadir}/dbus-1/system.d/com.redhat.tuned.conf @@ -304,6 +353,7 @@ rm %{buildroot}%{_mandir}/man7/tuned-profiles-sap-hana.7 %files profiles-sap-hana %{profile_dir}/sap-hana +%{profile_dir}/sap-hana-kvm-guest %{_mandir}/man7/tuned-profiles-sap-hana.7%{?ext_man} %endif @@ -330,12 +380,12 @@ rm %{buildroot}%{_mandir}/man7/tuned-profiles-sap-hana.7 %files profiles-postgresql %defattr(-,root,root,-) -%{_prefix}/lib/tuned/postgresql +%{profile_dir}/postgresql %{_mandir}/man7/tuned-profiles-postgresql.7* %files profiles-spectrumscale %defattr(-,root,root,-) -%{_prefix}/lib/tuned/spectrumscale-ece +%{profile_dir}/spectrumscale-ece %{_mandir}/man7/tuned-profiles-spectrumscale-ece.7* %files profiles-openshift @@ -361,4 +411,15 @@ rm %{buildroot}%{_mandir}/man7/tuned-profiles-sap-hana.7 %{_mandir}/man8/diskdevstat.* %{_mandir}/man8/scomes.* +%files ppd +%{_sbindir}/tuned-ppd +%{_unitdir}/tuned-ppd.service +%{_datadir}/dbus-1/system-services/net.hadess.PowerProfiles.service +%{_datadir}/dbus-1/system.d/net.hadess.PowerProfiles.conf +%{_datadir}/polkit-1/actions/net.hadess.PowerProfiles.policy +%{_datadir}/dbus-1/system-services/org.freedesktop.UPower.PowerProfiles.service +%{_datadir}/dbus-1/system.d/org.freedesktop.UPower.PowerProfiles.conf +%{_datadir}/polkit-1/actions/org.freedesktop.UPower.PowerProfiles.policy +%config(noreplace) %{_sysconfdir}/tuned/ppd.conf + %changelog