Skip site navigation (1) Skip section navigation (2)

Re: For what should pg_stop_backup wait?

From: Simon Riggs <simon(at)2ndquadrant(dot)com>
To: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: For what should pg_stop_backup wait?
Date: 2008-08-08 14:02:30
Message-ID: 1218204150.4549.610.camel@ebony.2ndQuadrant (view raw or flat)
Thread:
Lists: pgsql-hackers
On Fri, 2008-08-08 at 12:57 +0100, Simon Riggs wrote:

> > Yes, statement_timeout may help. But, I don't want to use it, because the
> > *successful* backup is canceled.
> > 
> > How about checking whether the stoppoint was archived by comparing with
> > the last WAL archived. The archiver process can tell the last WAL archived.
> > Or, we can calculate it from the status file.
> 
> I think its easier to test whether the stopxlogfilename still exists in
> pg_xlog. If not, we know it has been archived away. We can add that as
> an extra condition inside the loop.
> 
> So thinking we should test XLogArchiveCheckDone() for both
> stopxlogfilename and history file and then stat for the stop WAL file:

This seems better.

-- 
 Simon Riggs           www.2ndQuadrant.com
 PostgreSQL Training, Services and Support

Attachment: stop_backup_wait_bug.v2.patch
Description: text/x-patch (2.5 KB)

In response to

Responses

pgsql-hackers by date

Next:From: Tom LaneDate: 2008-08-08 14:11:19
Subject: Re: Oprofile with postgresql
Previous:From: Tom LaneDate: 2008-08-08 13:42:41
Subject: Re: patch: Add columns via CREATE OR REPLACE VIEW

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group