File tree Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Original file line number Diff line number Diff line change @@ -175,6 +175,28 @@ pgBackupValidate(pgBackup *backup, pgRestoreParams *params)
175175 elog (WARNING , "Backup %s data files are corrupted" , base36enc (backup -> start_time ));
176176 else
177177 elog (INFO , "Backup %s data files are valid" , base36enc (backup -> start_time ));
178+
179+ /* Issue #132 kludge */
180+ if (!corrupted &&
181+ ((parse_program_version (backup -> program_version ) == 20104 )||
182+ (parse_program_version (backup -> program_version ) == 20105 )||
183+ (parse_program_version (backup -> program_version ) == 20201 )))
184+ {
185+ char path [MAXPGPATH ];
186+
187+ pgBackupGetPath (backup , path , lengthof (path ), DATABASE_FILE_LIST );
188+
189+ if (pgFileSize (path ) >= (BLCKSZ * 500 ))
190+ {
191+ elog (WARNING , "Backup %s is a victim of metadata corruption. "
192+ "Additional information can be found here: "
193+ "https://github.com/postgrespro/pg_probackup/issues/132" ,
194+ base36enc (backup -> start_time ));
195+ backup -> status = BACKUP_STATUS_CORRUPT ;
196+ write_backup_status (backup , BACKUP_STATUS_CORRUPT , instance_name );
197+ }
198+
199+ }
178200}
179201
180202/*
You can’t perform that action at this time.
0 commit comments