Re: pgsql: Document that a CHECKPOINT before taking a file system snapshot - Mailing list pgsql-committers

From Bruce Momjian
Subject Re: pgsql: Document that a CHECKPOINT before taking a file system snapshot
Date
Msg-id 201011250301.oAP314S19309@momjian.us
Whole thread Raw
In response to Re: pgsql: Document that a CHECKPOINT before taking a file system snapshot  (Cédric Villemain <cedric.villemain.debian@gmail.com>)
List pgsql-committers
C�dric Villemain wrote:
> 2010/11/25 Bruce Momjian <bruce@momjian.us>:
> > Document that a CHECKPOINT before taking a file system snapshot can
> > reduce recovery time.
>
> I didn't follow that on -hackers, but :
>
> * checkpoint take place in the pg_start_backup process (before it
> releases the hand, so before you can start snapshoting)
>
> * we used to issue a checkpoint *before* pg_start_backup to reduce
> pg_start_backup duration  in case you have wal_archiving turn off and
> full_page_write is off, it reduces a bit the IO contention. (or even
> if not I hate seing this pg_start_backup taking seconds/minutes to
> finish)
>
> How the checkpoint before will reduce recovery time ?

This is for using file system snapshots, not PITR or continuous
archiving.  The checkpoint reduces how much WAL has to be replayed.

--
  Bruce Momjian  <bruce@momjian.us>        http://momjian.us
  EnterpriseDB                             http://enterprisedb.com

  + It's impossible for everything to be true. +

pgsql-committers by date:

Previous
From: Bruce Momjian
Date:
Subject: pgsql: Properly add new inet_net_ntop file to libpq Makefile.
Next
From: Robert Haas
Date:
Subject: pgsql: Remove belt-and-suspenders guards against buffer pin leaks.