Re: [PATCHES] Doc update for pg_start_backup

From: Jim Nasby <decibel(at)decibel(dot)org>
To: Heikki Linnakangas <heikki(at)enterprisedb(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)postgreSQL(dot)org, Simon Riggs <simon(at)2ndquadrant(dot)com>
Subject: Re: [PATCHES] Doc update for pg_start_backup
Date: 2007-06-29 13:28:47
Message-ID: 3D8ABCB6-2B65-42EC-A9DC-72ABA310E790@decibel.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

On Jun 29, 2007, at 3:25 AM, Heikki Linnakangas wrote:
> Tom Lane wrote:
>> Heikki Linnakangas <heikki(at)enterprisedb(dot)com> writes:
>>> Added a note to the docs that pg_start_backup can take a long
>>> time to finish now that we spread out checkpoints:
>> I was starting to wordsmith this, and then wondered whether it's not
>> just a stupid idea for pg_start_backup to act that way. The reason
>> you're doing it is to take a base backup, right? What are you going
>> to take the base backup with? I do not offhand know of any backup
>> tools that don't suck major amounts of I/O bandwidth.
>
> scp over a network? It's still going to consume a fair amount of I/
> O, but the network could very well be the bottleneck.

You can also use rsync and have it do bandwidth limiting (AFAIK that
would work locally too).

>> That being
>> the case, you're simply not going to schedule the operation during
>> full-load periods. And that leads to the conclusion that
>> pg_start_backup should just use CHECKPOINT_IMMEDIATE and not slow
>> you down.
>
> That's probably true in most cases. But on a system that doesn't
> have quite periods, you're still going to have to take the backup.

Correct. If the load presented by the base backup is too high, you'll
be looking at ways to slow it down; but I've yet to run across such a
case in the field.

I think having start_backup do a checkpoint immediate by default
would be best, since it's least surprising, but I do like having it
as an option for cases where it's needed (though I think those cases
are probably pretty rare).
--
Jim Nasby jim(at)nasby(dot)net
EnterpriseDB http://enterprisedb.com 512.569.9461 (cell)

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Magnus Hagander 2007-06-29 13:32:19 Re: pg_dump and minor versions
Previous Message Michael Enke 2007-06-29 13:28:17 Re: self defined data type "with limit"?

Browse pgsql-patches by date

  From Date Subject
Next Message Andrew Dunstan 2007-06-29 14:49:28 Re: WIP CSV logs
Previous Message Theo Schlossnagle 2007-06-29 12:33:43 Re: [PATCHES] Doc update for pg_start_backup