Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 4df1328

Browse files
committed
Put back stats-collector restarting code, removed accidentally.
Removed that code snippet accidentally in the archive_mode='always' patch. Also, use varname-tags for archive_command in the docs. Fujii Masao
1 parent d773b55 commit 4df1328

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

doc/src/sgml/high-availability.sgml

+4-3
Original file line numberDiff line numberDiff line change
@@ -1237,9 +1237,10 @@ primary_slot_name = 'node_a_slot'
12371237
to <literal>always</literal>, and the standby will call the archive
12381238
command for every WAL segment it receives, whether it's by restoring
12391239
from the archive or by streaming replication. The shared archive can
1240-
be handled similarly, but the archive_command must test if the file
1241-
being archived exists already, and if the existing file has identical
1242-
contents. This requires more care in the archive_command, as it must
1240+
be handled similarly, but the <varname>archive_command</varname> must
1241+
test if the file being archived exists already, and if the existing file
1242+
has identical contents. This requires more care in the
1243+
<varname>archive_command</varname>, as it must
12431244
be careful to not overwrite an existing file with different contents,
12441245
but return success if the exactly same file is archived twice. And
12451246
all that must be done free of race conditions, if two servers attempt

src/backend/postmaster/postmaster.c

+4
Original file line numberDiff line numberDiff line change
@@ -1645,6 +1645,10 @@ ServerLoop(void)
16451645
start_autovac_launcher = false; /* signal processed */
16461646
}
16471647

1648+
/* If we have lost the stats collector, try to start a new one */
1649+
if (PgStatPID == 0 && pmState == PM_RUN)
1650+
PgStatPID = pgstat_start();
1651+
16481652
/*
16491653
* If we have lost the archiver, try to start a new one.
16501654
*

0 commit comments

Comments
 (0)