From 08936eb07c4534b43f49972ff181a4e0372a2d8a Mon Sep 17 00:00:00 2001 From: zhouwenpei Date: Wed, 10 Jan 2024 01:21:16 +0000 Subject: [PATCH] fix upgrade problem that sysstat.service changes from disable to enable (cherry picked from commit 1aa8f566b339f937ffcd09011c1b62619c0e1406) --- sysstat.spec | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sysstat.spec b/sysstat.spec index 5b21d0b..fdf17d8 100644 --- a/sysstat.spec +++ b/sysstat.spec @@ -1,6 +1,6 @@ Name: sysstat Version: 12.5.4 -Release: 9 +Release: 10 Summary: System performance tools for the Linux operating system License: GPLv2+ URL: http://sebastien.godard.pagesperso-orange.fr/ @@ -80,7 +80,9 @@ export compressafter="31" %systemd_postun sysstat.service sysstat-collect.timer sysstat-summary.timer %posttrans -/usr/bin/systemctl enable sysstat.service >/dev/null 2>&1 +if [ "$(systemctl is-enable sysstat.service)" == "enabled" ] ; then + /usr/bin/systemctl enable sysstat.service >/dev/null 2>&1 +fi %files -f %{name}.lang %doc CHANGES COPYING CREDITS FAQ.md README.md %{name}-%{version}.lsm @@ -93,6 +95,9 @@ export compressafter="31" %{_mandir}/man*/* %changelog +* Wed Jan 10 2024 zhouwenpei - 12.5.4-10 +- fix upgrade problem that sysstat.service changes from disable to enable + * Wed Jun 14 2023 zhouwenpei - 12.5.4-9 - Try to avoid negative values -- Gitee