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

Commitac4ea5e

Browse files
committed
bugfix: exit with error if validation after backup found corruption
1 parentd27835d commitac4ea5e

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

‎src/backup.c‎

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -996,10 +996,14 @@ do_backup(time_t start_time, bool no_validate)
996996
if (!no_validate)
997997
pgBackupValidate(&current);
998998

999-
elog(INFO,"Backup %s completed",base36enc(current.start_time));
999+
if (current.status==BACKUP_STATUS_OK||
1000+
current.status==BACKUP_STATUS_DONE)
1001+
elog(INFO,"Backup %s completed",base36enc(current.start_time));
1002+
else
1003+
elog(ERROR,"Backup %s failed",base36enc(current.start_time));
10001004

10011005
/*
1002-
* Aftersuccessfil backup completion remove backups
1006+
* Aftersuccessful backup completion remove backups
10031007
* which are expired according to retention policies
10041008
*/
10051009
if (delete_expired||merge_expired||delete_wal)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp