On Tue, Apr 23, 2013 at 2:30 AM, Andres Freund <and...@2ndquadrant.com>wrote:

> On 2013-04-23 14:51:05 +0530, Pavan Deolasee wrote:
>
> > [pavan.deolasee@puppetserver pg_xlogdump]$ ./pg_xlogdump
> > ~/db93head/pg_xlog/000000010000000000000008
> > pg_xlogdump: FATAL:  could not find a valid record after 0/8000000
> >
> > So pg_xlogdump gives error for all WAL files except the first one. Should
> > it not have printed the WAL records from these files ?
>
> Probably not. Those are likely renamed wal files that do not yet contain
> valid data.
>

But they do contain valid data, just not for the name the file currently
has.  If you can guess what the pre-recycle name was, you can rename the
file (as an out-of-tree copy of course) and then get the dump out of it,
which I've found can be quite useful.  Perhaps there should be an option
for it to "press on regardless" and dump the contents as if it were the
pre-recycled file.  Or maybe just have the error message report to you what
filename the data it sees would be valid for, so you can know what to
rename it to without needing to guess.  I don't really know how this would
interact with STARTSEG and ENDSEG range, though, so perhaps it would only
apply when just one file is given, not a range.

Cheers,

Jeff

Reply via email to