File tree 3 files changed +19
-14
lines changed
3 files changed +19
-14
lines changed Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ DISTCHECK_CONFIGURE_FLAGS = \
43
43
SUBDIRS = . tests
44
44
45
45
bin_SCRIPTS = $(setup )
46
- libexec_SCRIPTS = $(ctl ) $( checkdb )
46
+ libexec_SCRIPTS = $(checkdb )
47
47
48
48
legacyscriptsdir = $(systemdlegacyscriptsdir ) /$(NAME_SERVICE )
49
49
@@ -52,7 +52,8 @@ noinst_DATA =
52
52
# TODO: Ideally, 'make distcheck' should check every file we generate.
53
53
if WANT_SYSVINIT
54
54
noinst_DATA += $(initscript )
55
- GENERATED_FILES += $(initscript )
55
+ libexec_SCRIPTS += $(ctl )
56
+ GENERATED_FILES += $(initscript ) $(ctl )
56
57
else
57
58
systemdunits_DATA = $(service ) $(serviceat )
58
59
legacyscripts_SCRIPTS = initdb upgrade
Original file line number Diff line number Diff line change 1
1
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2
2
3
+ New in 8.0 version:
4
+
5
+ * PostgreSQL on systems with systemd are now configured with
6
+ --with-systemd, which simplifies the start/stop handling (we can
7
+ stop shipping postgresql-ctl wrapper, e.g.).
8
+
9
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
10
+
3
11
New in 7.0 version:
4
12
5
13
* RPM macros file works with SCLs, too.
Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ Description=PostgreSQL database server
9
9
After=network.target
10
10
11
11
[Service]
12
- Type=forking
12
+ Type=notify
13
13
14
14
User=postgres
15
15
Group=postgres
@@ -26,20 +26,16 @@ OOMScoreAdjust=-1000
26
26
Environment=PG_OOM_ADJUST_FILE=/proc/self/oom_score_adj
27
27
Environment=PG_OOM_ADJUST_VALUE=0
28
28
29
- # Maximum number of seconds pg_ctl will wait for postgres to start. Note that
30
- # PGSTARTTIMEOUT should be less than TimeoutSec value.
31
- Environment=PGSTARTTIMEOUT=270
32
-
33
29
@PGDATA_ENVIRONMENT@
34
30
35
31
ExecStartPre=@libexecdir@/postgresql-check-db-dir %N
36
-
37
- # Use convenient postgresql-ctl wrapper instead of directly pg_ctl. See the
38
- # postgresql-ctl file itself for more info .
39
-
40
- ExecStart=@libexecdir@/postgresql-ctl start -D ${PGDATA} -s -w -t ${PGSTARTTIMEOUT}
41
- ExecStop=@libexecdir@/postgresql-ctl stop -D ${PGDATA} -s -m fast
42
- ExecReload=@libexecdir@/postgresql-ctl reload -D ${PGDATA} -s
32
+ # Even though the $PGDATA variable is exported (postmaster would accept that)
33
+ # use the -D option here so PGDATA content is printed by /bin/ps and by
34
+ # 'systemctl status' .
35
+ ExecStart=@bindir@/postmaster -D ${PGDATA}
36
+ ExecReload=/bin/kill -HUP $MAINPID
37
+ KillMode=mixed
38
+ KillSignal=SIGINT
43
39
44
40
# Give a reasonable amount of time for the server to start up/shut down.
45
41
# Ideally, the timeout for starting PostgreSQL server should be handled more
You can’t perform that action at this time.
0 commit comments