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

Re: Improve shutdown during online backup

From: Simon Riggs <simon(at)2ndquadrant(dot)com>
To: Albe Laurenz <laurenz(dot)albe(at)wien(dot)gv(dot)at>
Cc: pgsql-patches(at)postgresql(dot)org
Subject: Re: Improve shutdown during online backup
Date: 2008-04-01 16:42:21
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackerspgsql-patches
On Tue, 2008-04-01 at 15:34 +0200, Albe Laurenz wrote:
> This follows up on the discussion in
> - pg_ctl will refuse a smart shutdown during online backup.
> - The postmaster will also refuse to shutdown in smart mode
>   in that case and log a message to that effect.
> - In fast shutdown mode, the server will rename "backup_label"
>   after successfully shutting down and log the fact.

Looks good.

Few comments:

* smart shutdown waits for sessions to complete, yet this just ignores
smart shutdowns which is something a little different. I think we 
should wait for the backup to complete and then shutdown.

* when we say "online backup cancelled" I think we should say something
more like "online backup mode cancelled". All we are doing is removing
the backup label file, we're not actually cancelling the physical backup
since it is external to the database anyway.

* The #defines at top of postmaster.c are duplicated from xlog.c
If we can't agree on a common header file then we should at least add a
comment to mention they are duplicated (in both locations).

  Simon Riggs

  PostgreSQL UK 2008 Conference:

In response to


pgsql-hackers by date

Next:From: Aidan Van DykDate: 2008-04-01 16:53:56
Subject: Re: Several tags around PostgreSQL 7.1 broken
Previous:From: David FetterDate: 2008-04-01 16:35:03
Subject: Re: Cast as compound type

pgsql-patches by date

Next:From: Simon RiggsDate: 2008-04-01 19:03:18
Subject: Re: Improve shutdown during online backup
Previous:From: Simon RiggsDate: 2008-04-01 16:17:34
Subject: Re: [HACKERS] Minor changes to Recovery related code

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