pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alvaro Herrera <alvherre@2ndquadrant.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Dave Stibrany <dstibrany@gmail.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: Does my pg_xlog directory look right?
Date: Fri, 20 May 2016 14:41:26 -0400
Message-ID: <20160520184126.GA333087@alvherre.pgsql> (raw)
In-Reply-To: <54621.1463769300@sss.pgh.pa.us>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-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


-- 
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin



view thread (4+ messages)  latest in thread

Message-ID: <20160520184126.GA333087@alvherre.pgsql>
Permalink:  ../20160520184126.GA333087@alvherre.pgsql/
Also on:    postgresql.org/message-id/20160520184126.GA333087@alvherre.pgsql

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: alvherre@2ndquadrant.com, tgl@sss.pgh.pa.us, dstibrany@gmail.com
  Subject: Re: Does my pg_xlog directory look right?
  In-Reply-To: <20160520184126.GA333087@alvherre.pgsql>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox