pg_rewind and xlogtemp files - Mailing list pgsql-hackers

From Michael Paquier
Subject pg_rewind and xlogtemp files
Date
Msg-id CAB7nPqT=nPzXseCyrJ-yvKvE-Q+vC42Cc1VvGcdsEiWb0AZL1w@mail.gmail.com
Whole thread Raw
Responses Re: pg_rewind and xlogtemp files  (Michael Paquier <michael.paquier@gmail.com>)
List pgsql-hackers
Hi all,

I just bumped into this report regarding pg_rewind, that impacts as
well the version shipped in src/bin/pg_rewind:
https://github.com/vmware/pg_rewind/issues/45

In short, the issue refers to the fact that if the source server
filemap includes xlogtemp files pg_rewind will surely fail with
something like the following error:

error reading xlog record: record with zero length at 1/D5000090
unexpected result while fetching remote files: ERROR:  could not open
file "pg_xlog/xlogtemp.23056" for reading: No such file or directory

The servers diverged at WAL position 1/D4A081B0 on timeline 174.
Rewinding from Last common checkpoint at 1/D30A5650 on timeline 174

As pointed by dev1ant on the original bug report, process_remote_file
should ignore files named as pg_xlog/xlogtemp.*, and I think that this
is the right thing to do. Any objections for a patch that at the same
time makes "xlogtemp." a define declaration in xlog_internal.h?

Regards,
-- 
Michael



pgsql-hackers by date:

Previous
From: Noah Misch
Date:
Subject: Re: 9.5 release scheduling (was Re: logical column ordering)
Next
From: Fabien COELHO
Date:
Subject: Re: checkpointer continuous flushing