import pcp-5.3.5-8.el8
This commit is contained in:
parent
d0a48ffa98
commit
f4ce0476d8
83
SOURCES/redhat-bugzilla-1991763.patch
Normal file
83
SOURCES/redhat-bugzilla-1991763.patch
Normal file
@ -0,0 +1,83 @@
|
||||
commit 69c7d9bf5ac24bda51f8c876dc258bfe054b7cf8
|
||||
Author: Sunil Mohan Adapa <sunil@medhas.org>
|
||||
Date: Tue Feb 1 09:55:23 2022 -0800
|
||||
|
||||
pmlogger: zeroconf: Prioritize user configuration over zeroconf
|
||||
|
||||
In 2c17ba0cc16f58de511dff1e3122096d60c50bb0, zeroconf provided
|
||||
defaults (/usr/share/pcp/zeroconf/pmlogger, which was actually
|
||||
/etc/sysconf/pmlogger_zeroconf at the time of the change) were prioritized over
|
||||
user configuration (/etc/sysconf/pmlogger). This lead to regression in clients
|
||||
which edited the user configuration and expected the changes to be given
|
||||
priority over zeroconf configuration. This was identified at least in
|
||||
ansible-pcp[1].
|
||||
|
||||
Undo the changes in this commit so that the final priority is as follows:
|
||||
|
||||
User configuration (/etc/sysconfig/pmlogger)
|
||||
(priority over)
|
||||
Zeroconf defaults (/usr/share/pcp/zeroconf/pmlogger)
|
||||
(priority over)
|
||||
Code defaults (pmlogger.c)
|
||||
|
||||
Links:
|
||||
|
||||
1) https://github.com/performancecopilot/pcp/pull/1462#issuecomment-1022714960
|
||||
|
||||
Tests:
|
||||
|
||||
- Install pcp. Ensure pmlogger is running. Notice that there is no
|
||||
PMLOGGER_INTERVAL set in the pmlogger daemon's environment.
|
||||
|
||||
- Install pcp-zeroconf. Restart pmlogger. Notice that PMLOGGER_INTERVAL
|
||||
environment is set in the pmlogger daemon's environment. The value is 10.
|
||||
|
||||
- Edit /etc/sysconfig/pmlogger and set the value of PMLOGGER_INTERVAL to 15.
|
||||
Restart pmlogger and notice that PMLOGGER_INTERVAL is set to 15 in pmlogger
|
||||
daemon's environment.
|
||||
|
||||
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
|
||||
Tested-by: Sunil Mohan Adapa <sunil@medhas.org>
|
||||
|
||||
diff --git a/src/pmlogger/pmlogger.defaults b/src/pmlogger/pmlogger.defaults
|
||||
index 1765760b5..1e96cd6ff 100644
|
||||
--- a/src/pmlogger/pmlogger.defaults
|
||||
+++ b/src/pmlogger/pmlogger.defaults
|
||||
@@ -1,7 +1,7 @@
|
||||
# Environment variables for the primary pmlogger daemon. See also
|
||||
# the pmlogger control file and pmlogconf(1) for additional details.
|
||||
-# Settings defined in this file will be overridden by any settings
|
||||
-# in the pmlogger zeroconf file (if present).
|
||||
+# Settings defined in this file will override any settings in the
|
||||
+# pmlogger zeroconf file (if present).
|
||||
|
||||
# Behaviour regarding listening on external-facing interfaces;
|
||||
# unset PMLOGGER_LOCAL to allow connections from remote hosts.
|
||||
diff --git a/src/pmlogger/pmlogger.zeroconf b/src/pmlogger/pmlogger.zeroconf
|
||||
index 9defc6e3d..fe86dedcc 100644
|
||||
--- a/src/pmlogger/pmlogger.zeroconf
|
||||
+++ b/src/pmlogger/pmlogger.zeroconf
|
||||
@@ -1,6 +1,6 @@
|
||||
#
|
||||
-# PMLOGGER environment variables defined in this file take precedence over
|
||||
-# the same variables defined in the standard pmlogger config file.
|
||||
+# PMLOGGER environment variables defined in the standard pmlogger config file
|
||||
+# take precedence over the same variables defined in this file.
|
||||
#
|
||||
# The PMLOGGER_INTERVAL setting affects the default primary pmlogger recording
|
||||
# frequency. This only affects the *default* interval setting when specified
|
||||
diff --git a/src/pmlogger/pmlogger_check.sh b/src/pmlogger/pmlogger_check.sh
|
||||
index 6cc2a8ed7..64750cb5f 100755
|
||||
--- a/src/pmlogger/pmlogger_check.sh
|
||||
+++ b/src/pmlogger/pmlogger_check.sh
|
||||
@@ -983,8 +983,8 @@ END { print m }'`
|
||||
then
|
||||
if [ "X$primary" = Xy ]
|
||||
then
|
||||
- # pcp-zeroconf environment variables (if present) take precedence
|
||||
- envs=`grep -h ^PMLOGGER "$PMLOGGERENVS" "$PMLOGGERZEROCONFENVS" 2>/dev/null`
|
||||
+ # User configuration takes precedence over pcp-zeroconf
|
||||
+ envs=`grep -h ^PMLOGGER "$PMLOGGERZEROCONFENVS" "$PMLOGGERENVS" 2>/dev/null`
|
||||
args="-P $args"
|
||||
iam=" primary"
|
||||
# clean up port-map, just in case
|
@ -1,6 +1,6 @@
|
||||
Name: pcp
|
||||
Version: 5.3.5
|
||||
Release: 7%{?dist}
|
||||
Release: 8%{?dist}
|
||||
Summary: System-level performance monitoring and performance management
|
||||
License: GPLv2+ and LGPLv2+ and CC-BY
|
||||
URL: https://pcp.io
|
||||
@ -16,6 +16,7 @@ Patch4: redhat-bugzilla-2030140.patch
|
||||
Patch5: redhat-bugzilla-2003956.patch
|
||||
Patch6: redhat-bugzilla-2003956-pmdabcc-update-kernel-version-check-due-to-backporting.patch
|
||||
Patch7: redhat-bugzilla-1973833.patch
|
||||
Patch8: redhat-bugzilla-1991763.patch
|
||||
|
||||
%if 0%{?fedora} >= 26 || 0%{?rhel} > 7
|
||||
%global __python2 python2
|
||||
@ -2289,6 +2290,7 @@ updated policy package.
|
||||
%patch5 -p1
|
||||
%patch6 -p1
|
||||
%patch7 -p1
|
||||
%patch8 -p1
|
||||
|
||||
%build
|
||||
# the buildsubdir macro gets defined in %setup and is apparently only available in the next step (i.e. the %build step)
|
||||
@ -2691,10 +2693,8 @@ exit 0
|
||||
chown -R pcpqa:pcpqa %{_testsdir} 2>/dev/null
|
||||
%if 0%{?rhel}
|
||||
%if !%{disable_systemd}
|
||||
systemctl restart pmcd >/dev/null 2>&1
|
||||
systemctl restart pmlogger >/dev/null 2>&1
|
||||
systemctl enable pmcd >/dev/null 2>&1
|
||||
systemctl enable pmlogger >/dev/null 2>&1
|
||||
systemctl restart pmcd pmlogger >/dev/null 2>&1
|
||||
systemctl enable pmcd pmlogger >/dev/null 2>&1
|
||||
%else
|
||||
/sbin/chkconfig --add pmcd >/dev/null 2>&1
|
||||
/sbin/chkconfig --add pmlogger >/dev/null 2>&1
|
||||
@ -2957,8 +2957,7 @@ exit 0
|
||||
%preun zeroconf
|
||||
if [ "$1" -eq 0 ]
|
||||
then
|
||||
%systemd_preun pmlogger_daily_report.timer
|
||||
%systemd_preun pmlogger_daily_report.service
|
||||
%systemd_preun pmlogger_daily_report.timer pmlogger_daily_report.service
|
||||
fi
|
||||
%endif
|
||||
|
||||
@ -2967,27 +2966,9 @@ if [ "$1" -eq 0 ]
|
||||
then
|
||||
# stop daemons before erasing the package
|
||||
%if !%{disable_systemd}
|
||||
%systemd_preun pmlogger.service
|
||||
%systemd_preun pmlogger_check.timer
|
||||
%systemd_preun pmlogger_daily.timer
|
||||
%systemd_preun pmlogger_farm.service
|
||||
%systemd_preun pmlogger_farm_check.service
|
||||
%systemd_preun pmlogger_farm_check.timer
|
||||
%systemd_preun pmie.service
|
||||
%systemd_preun pmie_check.timer
|
||||
%systemd_preun pmie_daily.timer
|
||||
%systemd_preun pmie_farm.service
|
||||
%systemd_preun pmie_farm_check.service
|
||||
%systemd_preun pmie_farm_check.timer
|
||||
%systemd_preun pmproxy.service
|
||||
%systemd_preun pmfind.service
|
||||
%systemd_preun pmcd.service
|
||||
%systemd_preun pmlogger_check.timer pmlogger_daily.timer pmlogger_farm_check.timer pmlogger_farm_check.service pmlogger_farm.service pmlogger.service pmie_check.timer pmie_daily.timer pmie_farm_check.timer pmie_farm_check.service pmie_farm.service pmie.service pmproxy.service pmfind.service pmcd.service
|
||||
|
||||
systemctl stop pmlogger.service >/dev/null 2>&1
|
||||
systemctl stop pmie.service >/dev/null 2>&1
|
||||
systemctl stop pmproxy.service >/dev/null 2>&1
|
||||
systemctl stop pmfind.service >/dev/null 2>&1
|
||||
systemctl stop pmcd.service >/dev/null 2>&1
|
||||
systemctl stop pmlogger.service pmie.service pmproxy.service pmfind.service pmcd.service >/dev/null 2>&1
|
||||
%else
|
||||
/sbin/service pmlogger stop >/dev/null 2>&1
|
||||
/sbin/service pmie stop >/dev/null 2>&1
|
||||
@ -3020,12 +3001,8 @@ done
|
||||
pmieconf -c enable dmthin
|
||||
%if 0%{?rhel}
|
||||
%if !%{disable_systemd}
|
||||
systemctl restart pmcd >/dev/null 2>&1
|
||||
systemctl restart pmlogger >/dev/null 2>&1
|
||||
systemctl restart pmie >/dev/null 2>&1
|
||||
systemctl enable pmcd >/dev/null 2>&1
|
||||
systemctl enable pmlogger >/dev/null 2>&1
|
||||
systemctl enable pmie >/dev/null 2>&1
|
||||
systemctl restart pmcd pmlogger pmie >/dev/null 2>&1
|
||||
systemctl enable pmcd pmlogger pmie >/dev/null 2>&1
|
||||
%else
|
||||
/sbin/chkconfig --add pmcd >/dev/null 2>&1
|
||||
/sbin/chkconfig --add pmlogger >/dev/null 2>&1
|
||||
@ -3371,15 +3348,13 @@ PCP_LOG_DIR=%{_logsdir}
|
||||
%files zeroconf -f pcp-zeroconf-files.rpm
|
||||
|
||||
%changelog
|
||||
* Fri Jan 21 2022 Nathan Scott <nathans@redhat.com> - 5.3.5-7
|
||||
- Further improvements to the farm systemd services (BZ 2027753)
|
||||
* Wed Feb 02 2022 Nathan Scott <nathans@redhat.com> - 5.3.5-8
|
||||
- Fix pcp-zeroconf logger interval override regression (BZ 1991763)
|
||||
- Remove warnings from spec setup of PCP systemd units (BZ 2048024)
|
||||
|
||||
* Thu Dec 16 2021 Andreas Gerstmayr <agerstmayr@redhat.com> - 5.3.5-6
|
||||
- pmdabcc: update qa/1118 testcase to match new output (BZ 2003956)
|
||||
|
||||
* Thu Dec 16 2021 Nathan Scott <nathans@redhat.com> - 5.3.5-5
|
||||
- Further improvements to the farm systemd services (BZ 2027753)
|
||||
|
||||
* Wed Dec 15 2021 Nathan Scott <nathans@redhat.com> - 5.3.5-4
|
||||
- pmdabcc: resolve compilation issues of some bcc PMDA modules on
|
||||
aarch64, ppc64le and s390x (BZ 2003956)
|
||||
|
Loading…
Reference in New Issue
Block a user