public inbox for [email protected]
help / color / mirror / Atom feedFrom: Martín Marqués <[email protected]>
To: Jeff Frost <[email protected]>
Cc: Justin King <[email protected]>
Cc: [email protected]
Subject: Re: repmgr.service
Date: Wed, 30 Dec 2015 18:59:41 -0300
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <CAL3i3zT1NXVTyO=jOSXTnj3Uch9T569-LMyehDrUYqn0X+g2=w@mail.gmail.com>
<[email protected]>
<[email protected]>
List-Unsubscribe: <mailto:[email protected]?body=unsub%20pgsql-pkg-yum>
El 22/12/15 a las 23:52, Jeff Frost escribió:
> Sorry for the slow reply on this.
>
> We did make some changes recently, but it seems this was not one of them.
>
> A patch would definitely speed us up and would be most welcome!
Last patch of the day. The one with changes to the spec file.
Please check them and if there's something to fix let me know and I'll
take care of it next week.
Regards, and happy new year!
--
Martín Marqués http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
--
Sent via pgsql-pkg-yum mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-pkg-yum
Attachments:
[text/x-patch] 0001-Changes-to-the-spec-file-to-fix-a-few-issues.patch (44.9K, 2-0001-Changes-to-the-spec-file-to-fix-a-few-issues.patch)
download | inline diff:
From e87be2010c7dab69ab77ed965f1f9ad5eacef057 Mon Sep 17 00:00:00 2001
From: Martin <[email protected]>
Date: Wed, 30 Dec 2015 18:52:46 -0300
Subject: [PATCH] Changes to the spec file to fix a few issues: * Missing
/var/run/repmgr directory used for the PID file * Change user from repmgr to
postgres
---
rpm/redhat/9.3/repmgr/EL-5/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.3/repmgr/EL-6/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.3/repmgr/EL-7/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.3/repmgr/F-19/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.3/repmgr/F-20/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.3/repmgr/F-21/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.3/repmgr/F-22/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.3/repmgr/F-23/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.4/repmgr/EL-5/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.4/repmgr/EL-6/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.4/repmgr/EL-7/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.4/repmgr/F-20/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.4/repmgr/F-21/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.4/repmgr/F-22/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.4/repmgr/F-23/repmgr.spec | 21 +++++++++++++--------
rpm/redhat/9.5/repmgr/EL-5/repmgr.spec | 25 ++++++++++++-------------
rpm/redhat/9.5/repmgr/EL-6/repmgr.spec | 25 ++++++++++++-------------
rpm/redhat/9.5/repmgr/EL-7/repmgr.spec | 25 ++++++++++++-------------
rpm/redhat/9.5/repmgr/F-20/repmgr.spec | 25 ++++++++++++-------------
rpm/redhat/9.5/repmgr/F-21/repmgr.spec | 25 ++++++++++++-------------
rpm/redhat/9.5/repmgr/F-22/repmgr.spec | 25 ++++++++++++-------------
rpm/redhat/9.5/repmgr/F-23/repmgr.spec | 25 ++++++++++++-------------
22 files changed, 279 insertions(+), 211 deletions(-)
diff --git a/rpm/redhat/9.3/repmgr/EL-5/repmgr.spec b/rpm/redhat/9.3/repmgr/EL-5/repmgr.spec
index 36985e8..9563c90 100644
--- a/rpm/redhat/9.3/repmgr/EL-5/repmgr.spec
+++ b/rpm/redhat/9.3/repmgr/EL-5/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.3/repmgr/EL-6/repmgr.spec b/rpm/redhat/9.3/repmgr/EL-6/repmgr.spec
index 36985e8..9563c90 100644
--- a/rpm/redhat/9.3/repmgr/EL-6/repmgr.spec
+++ b/rpm/redhat/9.3/repmgr/EL-6/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.3/repmgr/EL-7/repmgr.spec b/rpm/redhat/9.3/repmgr/EL-7/repmgr.spec
index 36985e8..9563c90 100644
--- a/rpm/redhat/9.3/repmgr/EL-7/repmgr.spec
+++ b/rpm/redhat/9.3/repmgr/EL-7/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.3/repmgr/F-19/repmgr.spec b/rpm/redhat/9.3/repmgr/F-19/repmgr.spec
index 36985e8..9563c90 100644
--- a/rpm/redhat/9.3/repmgr/F-19/repmgr.spec
+++ b/rpm/redhat/9.3/repmgr/F-19/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.3/repmgr/F-20/repmgr.spec b/rpm/redhat/9.3/repmgr/F-20/repmgr.spec
index 36985e8..9563c90 100644
--- a/rpm/redhat/9.3/repmgr/F-20/repmgr.spec
+++ b/rpm/redhat/9.3/repmgr/F-20/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.3/repmgr/F-21/repmgr.spec b/rpm/redhat/9.3/repmgr/F-21/repmgr.spec
index 36985e8..9563c90 100644
--- a/rpm/redhat/9.3/repmgr/F-21/repmgr.spec
+++ b/rpm/redhat/9.3/repmgr/F-21/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.3/repmgr/F-22/repmgr.spec b/rpm/redhat/9.3/repmgr/F-22/repmgr.spec
index 36985e8..9563c90 100644
--- a/rpm/redhat/9.3/repmgr/F-22/repmgr.spec
+++ b/rpm/redhat/9.3/repmgr/F-22/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.3/repmgr/F-23/repmgr.spec b/rpm/redhat/9.3/repmgr/F-23/repmgr.spec
index 36985e8..9563c90 100644
--- a/rpm/redhat/9.3/repmgr/F-23/repmgr.spec
+++ b/rpm/redhat/9.3/repmgr/F-23/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.4/repmgr/EL-5/repmgr.spec b/rpm/redhat/9.4/repmgr/EL-5/repmgr.spec
index aba8b39..7397199 100644
--- a/rpm/redhat/9.4/repmgr/EL-5/repmgr.spec
+++ b/rpm/redhat/9.4/repmgr/EL-5/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.4/repmgr/EL-6/repmgr.spec b/rpm/redhat/9.4/repmgr/EL-6/repmgr.spec
index aba8b39..7397199 100644
--- a/rpm/redhat/9.4/repmgr/EL-6/repmgr.spec
+++ b/rpm/redhat/9.4/repmgr/EL-6/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.4/repmgr/EL-7/repmgr.spec b/rpm/redhat/9.4/repmgr/EL-7/repmgr.spec
index aba8b39..7397199 100644
--- a/rpm/redhat/9.4/repmgr/EL-7/repmgr.spec
+++ b/rpm/redhat/9.4/repmgr/EL-7/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.4/repmgr/F-20/repmgr.spec b/rpm/redhat/9.4/repmgr/F-20/repmgr.spec
index aba8b39..7397199 100644
--- a/rpm/redhat/9.4/repmgr/F-20/repmgr.spec
+++ b/rpm/redhat/9.4/repmgr/F-20/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.4/repmgr/F-21/repmgr.spec b/rpm/redhat/9.4/repmgr/F-21/repmgr.spec
index aba8b39..7397199 100644
--- a/rpm/redhat/9.4/repmgr/F-21/repmgr.spec
+++ b/rpm/redhat/9.4/repmgr/F-21/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.4/repmgr/F-22/repmgr.spec b/rpm/redhat/9.4/repmgr/F-22/repmgr.spec
index aba8b39..7397199 100644
--- a/rpm/redhat/9.4/repmgr/F-22/repmgr.spec
+++ b/rpm/redhat/9.4/repmgr/F-22/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.4/repmgr/F-23/repmgr.spec b/rpm/redhat/9.4/repmgr/F-23/repmgr.spec
index aba8b39..7397199 100644
--- a/rpm/redhat/9.4/repmgr/F-23/repmgr.spec
+++ b/rpm/redhat/9.4/repmgr/F-23/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 1%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,13 +97,18 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
-groupadd -r repmgr >/dev/null 2>&1 || :
-useradd -m -g repmgr -r -s /bin/bash \
- -c "repmgr" repmgr >/dev/null 2>&1 || :
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
- %{__chown} -R repmgr: /var/log/repmgr
+ %{__chown} -R postgres: /var/log/repmgr
+fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
fi
%post
@@ -115,7 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-%{__chown} repmgr: %{_localstatedir}/run/%{sname}
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
diff --git a/rpm/redhat/9.5/repmgr/EL-5/repmgr.spec b/rpm/redhat/9.5/repmgr/EL-5/repmgr.spec
index 224c6bf..774c08d 100644
--- a/rpm/redhat/9.5/repmgr/EL-5/repmgr.spec
+++ b/rpm/redhat/9.5/repmgr/EL-5/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,11 +97,19 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
%{__chown} -R postgres: /var/log/repmgr
fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
+fi
%post
/sbin/ldconfig
@@ -112,11 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-if [ ! -x %{_varrundir} ]
-then
- %{__mkdir} -m 700 %{_varrundir}
- %{__chown} -R postgres: %{_varrundir}
-fi
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
@@ -147,11 +151,6 @@ fi
%endif
%changelog
-* Mon Nov 9 2015 - Devrim Gündüz <[email protected]> 3.0.2-2
-- Ensure that /var/run/repmgr exists. Per Guillaume Lelarge.
-- Switch to postgres user while running the deamon, instead of
- repmgr user. Per recent complaints from Guillaume and Justin King.
-
* Tue Oct 6 2015 - Devrim Gündüz <[email protected]> 3.0.2-1
- Update to 3.0.2
diff --git a/rpm/redhat/9.5/repmgr/EL-6/repmgr.spec b/rpm/redhat/9.5/repmgr/EL-6/repmgr.spec
index 224c6bf..774c08d 100644
--- a/rpm/redhat/9.5/repmgr/EL-6/repmgr.spec
+++ b/rpm/redhat/9.5/repmgr/EL-6/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,11 +97,19 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
%{__chown} -R postgres: /var/log/repmgr
fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
+fi
%post
/sbin/ldconfig
@@ -112,11 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-if [ ! -x %{_varrundir} ]
-then
- %{__mkdir} -m 700 %{_varrundir}
- %{__chown} -R postgres: %{_varrundir}
-fi
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
@@ -147,11 +151,6 @@ fi
%endif
%changelog
-* Mon Nov 9 2015 - Devrim Gündüz <[email protected]> 3.0.2-2
-- Ensure that /var/run/repmgr exists. Per Guillaume Lelarge.
-- Switch to postgres user while running the deamon, instead of
- repmgr user. Per recent complaints from Guillaume and Justin King.
-
* Tue Oct 6 2015 - Devrim Gündüz <[email protected]> 3.0.2-1
- Update to 3.0.2
diff --git a/rpm/redhat/9.5/repmgr/EL-7/repmgr.spec b/rpm/redhat/9.5/repmgr/EL-7/repmgr.spec
index 224c6bf..774c08d 100644
--- a/rpm/redhat/9.5/repmgr/EL-7/repmgr.spec
+++ b/rpm/redhat/9.5/repmgr/EL-7/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,11 +97,19 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
%{__chown} -R postgres: /var/log/repmgr
fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
+fi
%post
/sbin/ldconfig
@@ -112,11 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-if [ ! -x %{_varrundir} ]
-then
- %{__mkdir} -m 700 %{_varrundir}
- %{__chown} -R postgres: %{_varrundir}
-fi
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
@@ -147,11 +151,6 @@ fi
%endif
%changelog
-* Mon Nov 9 2015 - Devrim Gündüz <[email protected]> 3.0.2-2
-- Ensure that /var/run/repmgr exists. Per Guillaume Lelarge.
-- Switch to postgres user while running the deamon, instead of
- repmgr user. Per recent complaints from Guillaume and Justin King.
-
* Tue Oct 6 2015 - Devrim Gündüz <[email protected]> 3.0.2-1
- Update to 3.0.2
diff --git a/rpm/redhat/9.5/repmgr/F-20/repmgr.spec b/rpm/redhat/9.5/repmgr/F-20/repmgr.spec
index 224c6bf..774c08d 100644
--- a/rpm/redhat/9.5/repmgr/F-20/repmgr.spec
+++ b/rpm/redhat/9.5/repmgr/F-20/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,11 +97,19 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
%{__chown} -R postgres: /var/log/repmgr
fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
+fi
%post
/sbin/ldconfig
@@ -112,11 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-if [ ! -x %{_varrundir} ]
-then
- %{__mkdir} -m 700 %{_varrundir}
- %{__chown} -R postgres: %{_varrundir}
-fi
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
@@ -147,11 +151,6 @@ fi
%endif
%changelog
-* Mon Nov 9 2015 - Devrim Gündüz <[email protected]> 3.0.2-2
-- Ensure that /var/run/repmgr exists. Per Guillaume Lelarge.
-- Switch to postgres user while running the deamon, instead of
- repmgr user. Per recent complaints from Guillaume and Justin King.
-
* Tue Oct 6 2015 - Devrim Gündüz <[email protected]> 3.0.2-1
- Update to 3.0.2
diff --git a/rpm/redhat/9.5/repmgr/F-21/repmgr.spec b/rpm/redhat/9.5/repmgr/F-21/repmgr.spec
index 224c6bf..774c08d 100644
--- a/rpm/redhat/9.5/repmgr/F-21/repmgr.spec
+++ b/rpm/redhat/9.5/repmgr/F-21/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,11 +97,19 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
%{__chown} -R postgres: /var/log/repmgr
fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
+fi
%post
/sbin/ldconfig
@@ -112,11 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-if [ ! -x %{_varrundir} ]
-then
- %{__mkdir} -m 700 %{_varrundir}
- %{__chown} -R postgres: %{_varrundir}
-fi
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
@@ -147,11 +151,6 @@ fi
%endif
%changelog
-* Mon Nov 9 2015 - Devrim Gündüz <[email protected]> 3.0.2-2
-- Ensure that /var/run/repmgr exists. Per Guillaume Lelarge.
-- Switch to postgres user while running the deamon, instead of
- repmgr user. Per recent complaints from Guillaume and Justin King.
-
* Tue Oct 6 2015 - Devrim Gündüz <[email protected]> 3.0.2-1
- Update to 3.0.2
diff --git a/rpm/redhat/9.5/repmgr/F-22/repmgr.spec b/rpm/redhat/9.5/repmgr/F-22/repmgr.spec
index 224c6bf..774c08d 100644
--- a/rpm/redhat/9.5/repmgr/F-22/repmgr.spec
+++ b/rpm/redhat/9.5/repmgr/F-22/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,11 +97,19 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
%{__chown} -R postgres: /var/log/repmgr
fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
+fi
%post
/sbin/ldconfig
@@ -112,11 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-if [ ! -x %{_varrundir} ]
-then
- %{__mkdir} -m 700 %{_varrundir}
- %{__chown} -R postgres: %{_varrundir}
-fi
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
@@ -147,11 +151,6 @@ fi
%endif
%changelog
-* Mon Nov 9 2015 - Devrim Gündüz <[email protected]> 3.0.2-2
-- Ensure that /var/run/repmgr exists. Per Guillaume Lelarge.
-- Switch to postgres user while running the deamon, instead of
- repmgr user. Per recent complaints from Guillaume and Justin King.
-
* Tue Oct 6 2015 - Devrim Gündüz <[email protected]> 3.0.2-1
- Update to 3.0.2
diff --git a/rpm/redhat/9.5/repmgr/F-23/repmgr.spec b/rpm/redhat/9.5/repmgr/F-23/repmgr.spec
index 224c6bf..774c08d 100644
--- a/rpm/redhat/9.5/repmgr/F-23/repmgr.spec
+++ b/rpm/redhat/9.5/repmgr/F-23/repmgr.spec
@@ -12,7 +12,7 @@
Name: %{sname}%{pgmajorversion}
Version: 3.0.2
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: Replication Manager for PostgreSQL Clusters
License: GPLv3
URL: http://www.repmgr.org
@@ -20,7 +20,7 @@ Source0: http://repmgr.org/download/%{sname}-%{version}.tar.gz
Source1: repmgr-%{pgpackageversion}.service
Source2: repmgr.init
Patch0: repmgr-makefile-pgxs.patch
-Patch1: repmgr.conf.sample.patch
+#Patch1: repmgr.conf.sample.patch
%if %{systemd_enabled}
BuildRequires: systemd
@@ -62,7 +62,7 @@ future PostgreSQL versions.
%prep
%setup -q -n %{sname}-%{version}
%patch0 -p0
-%patch1 -p0
+#%patch1 -p0
%build
USE_PGXS=1 %{__make} %{?_smp_mflags}
@@ -97,11 +97,19 @@ install -m 755 %{SOURCE2} %{buildroot}%{_sysconfdir}/init.d/%{sname}-%{pgpackag
%endif
%pre
+groupadd -r postgres >/dev/null 2>&1 || :
+useradd -m -g postgres -r -s /bin/bash \
+ -c "postgres" postgres >/dev/null 2>&1 || :
if [ ! -x /var/log/repmgr ]
then
%{__mkdir} -m 700 /var/log/repmgr
%{__chown} -R postgres: /var/log/repmgr
fi
+if [ ! -x /var/run/repmgr ]
+then
+ %{__mkdir} -m 700 /var/run/repmgr
+ %{__chown} -R postgres: /var/run/repmgr
+fi
%post
/sbin/ldconfig
@@ -112,11 +120,7 @@ fi
# This adds the proper /etc/rc*.d links for the script
/sbin/chkconfig --add %{sname}-%{pgpackageversion}
%endif
-if [ ! -x %{_varrundir} ]
-then
- %{__mkdir} -m 700 %{_varrundir}
- %{__chown} -R postgres: %{_varrundir}
-fi
+%{__chown} postgres: %{_localstatedir}/run/%{sname}
%postun -p /sbin/ldconfig
@@ -147,11 +151,6 @@ fi
%endif
%changelog
-* Mon Nov 9 2015 - Devrim Gündüz <[email protected]> 3.0.2-2
-- Ensure that /var/run/repmgr exists. Per Guillaume Lelarge.
-- Switch to postgres user while running the deamon, instead of
- repmgr user. Per recent complaints from Guillaume and Justin King.
-
* Tue Oct 6 2015 - Devrim Gündüz <[email protected]> 3.0.2-1
- Update to 3.0.2
--
2.5.0
view thread (16+ messages) latest in thread
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected], [email protected]
Subject: Re: repmgr.service
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox