Re: [HACKERS] File system snapshots for multiple file systems

2008-04-08 Thread Bruce Momjian
I have applied the following patch to document the use of continuous archiving backups to allow non-simultaneous snapshots. I don't think we want to go any farther to stop WAL recycling during back backups. --- Bruce Momjia

Re: [HACKERS] File system snapshots for multiple file systems

2008-04-08 Thread Heikki Linnakangas
Tom Lane wrote: Heikki Linnakangas <[EMAIL PROTECTED]> writes: What I was complaining/suggesting is that we should make what you did to actually work, because it's a lot simpler. And as Jonah pointed out, we'd need to inhibit checkpoints between pg_start_backup() and pg_stop_backup() to make i

Re: [HACKERS] File system snapshots for multiple file systems

2008-04-08 Thread Magnus Hagander
Tom Lane wrote: > Gregory Stark <[EMAIL PROTECTED]> writes: > > "Tom Lane" <[EMAIL PROTECTED]> writes: > >> Whether it's a good idea or not is a bit debatable though. I'm > >> concerned about the WAL partition filling up (--> PANIC), > >> especially if you forget to pg_stop_backup after getting yo

Re: [HACKERS] File system snapshots for multiple file systems

2008-04-08 Thread Tom Lane
Gregory Stark <[EMAIL PROTECTED]> writes: > "Tom Lane" <[EMAIL PROTECTED]> writes: >> Whether it's a good idea or not is a bit debatable though. I'm >> concerned about the WAL partition filling up (--> PANIC), especially >> if you forget to pg_stop_backup after getting your backup. > We check if

Re: [HACKERS] File system snapshots for multiple file systems

2008-04-08 Thread Gregory Stark
"Tom Lane" <[EMAIL PROTECTED]> writes: > Whether it's a good idea or not is a bit debatable though. I'm > concerned about the WAL partition filling up (--> PANIC), especially > if you forget to pg_stop_backup after getting your backup. We check if pg_start_backup in effect when we an ENOSPC erro

Re: [HACKERS] File system snapshots for multiple file systems

2008-04-08 Thread Tom Lane
Heikki Linnakangas <[EMAIL PROTECTED]> writes: > What I was complaining/suggesting is that we should make what you did to > actually work, because it's a lot simpler. And as Jonah pointed out, > we'd need to inhibit checkpoints between pg_start_backup() and > pg_stop_backup() to make it work. I

Re: [HACKERS] File system snapshots for multiple file systems

2008-04-08 Thread tomas
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Tue, Apr 08, 2008 at 08:52:03AM +0100, Heikki Linnakangas wrote: > [EMAIL PROTECTED] wrote: [...] > What I was complaining/suggesting is that we should make what you did to > actually work, because it's a lot simpler. And as Jonah pointed out, >

Re: [HACKERS] File system snapshots for multiple file systems

2008-04-08 Thread Heikki Linnakangas
[EMAIL PROTECTED] wrote: Checkpoinitng is definitely coolest. If your file system doesn't do that, rsync is a good poor man's replacement: first rsync (takes long) (or work from an older backup) pg_start_backup(...) rsync (should be much faster) rsync WAL pg_stop_backup()

Re: [HACKERS] File system snapshots for multiple file systems

2008-04-08 Thread tomas
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Mon, Apr 07, 2008 at 03:03:41PM -0400, Jonah H. Harris wrote: > On Mon, Apr 7, 2008 at 2:58 PM, Heikki Linnakangas > <[EMAIL PROTECTED]> wrote: > > Incidentally, I looked at this stuff just a couple of days ago, and it [...] > Or checkpoint, yes?

Re: [HACKERS] File system snapshots for multiple file systems

2008-04-08 Thread Heikki Linnakangas
Jonah H. Harris wrote: On Mon, Apr 7, 2008 at 2:58 PM, Heikki Linnakangas <[EMAIL PROTECTED]> wrote: Incidentally, I looked at this stuff just a couple of days ago, and it occurred to me that we really should make it easier to take a hot backup with that mechanism. We shouldn't require setting

Re: [HACKERS] File system snapshots for multiple file systems

2008-04-07 Thread Fujii Masao
Heikki Linnakangas wrote: 1. call pg_start_backup('foo') 2. tar/etc. the whole data directory, except for pg_xlog 3. tar pg_xlog 4. call pg_stop_backup() If we just made sure that we don't delete or recycle any WAL files while the backup is being taken, that would work, right? When is the bac

Re: [HACKERS] File system snapshots for multiple file systems

2008-04-07 Thread Bruce Momjian
Heikki Linnakangas wrote: > > However, it occurred to me that if someone turned on continuous arciving > > during the file system snapshots, then you could use PITR to recover > > from file system snapshots that were not simultaneous. > > > > Should this be documented? > > If you use continuous a

Re: [HACKERS] File system snapshots for multiple file systems

2008-04-07 Thread Jonah H. Harris
On Mon, Apr 7, 2008 at 2:58 PM, Heikki Linnakangas <[EMAIL PROTECTED]> wrote: > Incidentally, I looked at this stuff just a couple of days ago, and it > occurred to me that we really should make it easier to take a hot backup > with that mechanism. We shouldn't require setting up archive_command,

Re: [HACKERS] File system snapshots for multiple file systems

2008-04-07 Thread Heikki Linnakangas
Bruce Momjian wrote: Right now it isn't possible to use file system snapshots a reliable backup if you are using multiple file systems for tablespaces because most systems don't allow the simultaneous snapshoting of multiple file system. Our documentation mentions this: If your database