How to find the latest (partial) WAL file - Mailing list pgsql-general

From Just Someone
Subject How to find the latest (partial) WAL file
Date
Msg-id 36932f270604101541h588faeaanc5d294a27dda50a2@mail.gmail.com
Whole thread Raw
Responses Re: How to find the latest (partial) WAL file  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
What is the best way to find the latest partial WAL file?

Based on my tests, using the mtime isn't 100% accurate, as if a
pg_start_backup/pg_stop_backup() operation is run, the .backup file
created might be newer than the last WAL file. It also seems that the
WAL file related to the backup is being updated according to the
mtime. Using a file name is also not 100% accurate, as it seems that
postgres will recycle the archived files, giving them "future" names
before they are used, leaving the directory with files that are older
by name, but not yet with relevant data.

Is there a way to discover what is the real current WAL file? I've
read that one of the todo's for 8.2 is to handle partial files
archiving, but I'm looking for something I can use now.

Regards,

Guy.

--
Family management on rails: http://www.famundo.com - coming soon!
My development related blog: http://devblog.famundo.com

pgsql-general by date:

Previous
From: Tyler MacDonald
Date:
Subject: Re: Debian package for freeradius_postgresql module
Next
From: Tom Lane
Date:
Subject: Re: How to find the latest (partial) WAL file