Re: Does my pg_xlog directory look right? - Mailing list pgsql-admin

From Alvaro Herrera
Subject Re: Does my pg_xlog directory look right?
Date
Msg-id 20160520184126.GA333087@alvherre.pgsql
Whole thread Raw
In response to Re: Does my pg_xlog directory look right?  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-admin
Tom Lane wrote:

> No, it probably means that neither one has been written at all yet.
> Typically, when a WAL segment is deemed no longer needed, the file isn't
> physically removed but is merely renamed into place as a future segment.
> The idea is to reduce unnecessary filesystem work as we create and delete
> WAL segments.  You could check this out if you have pg_xlogdump at hand,
> by seeing whether the WAL file's first page header claims to belong to the
> segment indicated by the file name, or to some much-older segment.

This may be a good time to point out that pg_xlogdump fails completely
when a file's contents does not match the file name, with no indication
about what a better file name would be.  In other words, if a file has
been recycled and not written to yet under the new name, it doesn't tell
you anything useful.  This is pretty annoying.

--
Álvaro Herrera                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


pgsql-admin by date:

Previous
From: Tom Lane
Date:
Subject: Re: Does my pg_xlog directory look right?
Next
From: dstibrany@gmail.com
Date:
Subject: Re: Does my pg_xlog directory look right?