Bug 250012 - databases/postgresql-repmgr: fails to start if pid file does not exist
Summary: databases/postgresql-repmgr: fails to start if pid file does not exist
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Muhammad Moinur Rahman
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-09-30 19:19 UTC by Ole
Modified: 2020-10-25 01:22 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (bofh)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ole 2020-09-30 19:19:16 UTC
If the pid file does not exist the repmgrd fails to start.
I modified the rc script to fix the problem:

(...)
: ${repmgrd_enable:="NO"}
: ${repmgrd_user:="pgsql"}
: ${repmgrd_config="/usr/local/etc/repmgr.conf"}

command=/usr/local/bin/${name}
pidfile=/var/run/${name}.pid

touch $pidfile
chown $repmgrd_user $pidfile

command_args="-m -d -p $pidfile -f $repmgrd_config"
(...)
Comment 1 commit-hook freebsd_committer freebsd_triage 2020-10-24 23:52:42 UTC
A commit references this bug:

Author: bofh
Date: Sat Oct 24 23:52:39 UTC 2020
New revision: 553232
URL: https://svnweb.freebsd.org/changeset/ports/553232

Log:
  databases/postgresql-repmgr: Update version 5.1.0=>5.2.0

  - Fix service start if pid file doesn't exist [1]

  PR:		250012 [1]
  Submitted by:	ole@free.de [1]
  Relnotes:	https://repmgr.org/docs/current/release-5.2.0.html

Changes:
  head/databases/postgresql-repmgr/Makefile
  head/databases/postgresql-repmgr/distinfo
  head/databases/postgresql-repmgr/files/repmgrd.in
  head/databases/postgresql-repmgr/pkg-plist