Skip to content

Commit 38eb5d9

Browse files
committed
Prevent the unnecessary creation of .ready file for the timeline history file.
Previously .ready file was created for the timeline history file at the end of an archive recovery even when WAL archiving was not enabled. This creation is unnecessary and causes .ready file to remain infinitely. This commit changes an archive recovery so that it creates .ready file for the timeline history file only when WAL archiving is enabled. Backpatch to all supported versions.
1 parent 0ef754c commit 38eb5d9

File tree

1 file changed

+5
-2
lines changed
  • src/backend/access/transam

1 file changed

+5
-2
lines changed

src/backend/access/transam/xlog.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4877,8 +4877,11 @@ writeTimeLineHistory(TimeLineID newTLI, TimeLineID parentTLI,
48774877
#endif
48784878

48794879
/* The history file can be archived immediately. */
4880-
TLHistoryFileName(histfname, newTLI);
4881-
XLogArchiveNotify(histfname);
4880+
if (XLogArchivingActive())
4881+
{
4882+
TLHistoryFileName(histfname, newTLI);
4883+
XLogArchiveNotify(histfname);
4884+
}
48824885
}
48834886

48844887
/*

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy