Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit41f613f

Browse files
committed
Add HINT for restartpoint race with KeepFileRestoredFromArchive().
The five commits ending atcc2c7d6closed this race condition for v15+. For v14 through v10, add a HINT todiscourage studying the cosmetic problem.Reviewed by Kyotaro Horiguchi and David Steele.Discussion:https://postgr.es/m/20220731061747.GA3692882@rfd.leadboat.com
1 parent4ad4c1f commit41f613f

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

‎src/backend/access/transam/xlog.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3392,7 +3392,10 @@ XLogFileInit(XLogSegNo logsegno, bool *use_existent, bool use_lock)
33923392
if (fd<0)
33933393
ereport(ERROR,
33943394
(errcode_for_file_access(),
3395-
errmsg("could not open file \"%s\": %m",path)));
3395+
errmsg("could not open file \"%s\": %m",path),
3396+
(AmCheckpointerProcess() ?
3397+
errhint("This is known to fail occasionally during archive recovery, where it is harmless.") :
3398+
0)));
33963399

33973400
elog(DEBUG2,"done creating and filling new WAL file");
33983401

‎src/backend/storage/file/fd.c

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -748,7 +748,10 @@ durable_link_or_rename(const char *oldfile, const char *newfile, int elevel)
748748
ereport(elevel,
749749
(errcode_for_file_access(),
750750
errmsg("could not link file \"%s\" to \"%s\": %m",
751-
oldfile,newfile)));
751+
oldfile,newfile),
752+
(AmCheckpointerProcess() ?
753+
errhint("This is known to fail occasionally during archive recovery, where it is harmless.") :
754+
0)));
752755
return-1;
753756
}
754757
unlink(oldfile);
@@ -759,7 +762,10 @@ durable_link_or_rename(const char *oldfile, const char *newfile, int elevel)
759762
ereport(elevel,
760763
(errcode_for_file_access(),
761764
errmsg("could not rename file \"%s\" to \"%s\": %m",
762-
oldfile,newfile)));
765+
oldfile,newfile),
766+
(AmCheckpointerProcess() ?
767+
errhint("This is known to fail occasionally during archive recovery, where it is harmless.") :
768+
0)));
763769
return-1;
764770
}
765771
#endif

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp