From: Craig Ringer <craig@2ndquadrant.com>
To: John Scalia <jayknowsunix@gmail.com>
To: pgsql-admin@postgresql.org <pgsql-admin@postgresql.org>
Subject: Re: WAL segment management on a standby
Date: Mon, 14 Jul 2014 10:18:16 +0800
Message-ID: <53C33DE8.7000902@2ndquadrant.com> (raw)
In-Reply-To: <53C015AA.5070908@gmail.com>
References: <53C015AA.5070908@gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-admin>
On 07/12/2014 12:49 AM, John Scalia wrote:
> Again, thanks to all to have assisted me with getting the WAL segments
> to both my standby servers. Everything with that is now working quite
> well. I do have a related followup question, however. On these standby's
> nothing is built in to manage those WAL segments in the archive
> directory. Thus, that directory can grow to the point where it fills up
> the disk rather quickly. Any good strategies for dealing with the WAL
> segments that get put in there. Do I really need them after postgresql
> has copied them up into the pg_xlog directory? If so, how far back
> should I keep them? Yes, I know about keeping everything between
> backups. So, if my directory looks like:
>
> 00000000300000000C000000A1
> 00000000300000000C000000A2
> 00000000300000000C000000A3
> 00000000300000000C000000A3.backup
> 00000000300000000C000000A4
>
> Could I safely delete the *A1, *A2, and maybe even the *A3 files?
Take a look at the pg_archivecleanup tool.
You might also want to look at PgBarman to automate this.
--
Craig Ringer http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, 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
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: craig@2ndquadrant.com, jayknowsunix@gmail.com
Subject: Re: WAL segment management on a standby
In-Reply-To: <53C33DE8.7000902@2ndquadrant.com>
* 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