Re: Dividing progress/debug information in pg_standby, and stat before copy

From: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
To: Simon Riggs <simon(at)2ndQuadrant(dot)com>
Cc: Magnus Hagander <magnus(at)hagander(dot)net>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Greg Smith <greg(at)2ndquadrant(dot)com>, Selena Deckelmann <selenamarie(at)gmail(dot)com>, Josh Berkus <josh(at)agliodbs(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Dividing progress/debug information in pg_standby, and stat before copy
Date: 2010-01-26 11:54:30
Message-ID: 4B5ED7F6.9080103@enterprisedb.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Simon Riggs wrote:
> Currently, we had presumed
> that standby_mode = off would be the same as Warm Standby replication,
> using pg_standby or other.

That's still true. standby_mode=off is the same as what you have in PG
8.4. You can still use pg_standby etc. with that.

> pg_standby checks file size before returning. If you just use "cp" as
> suggested then it would fail because the copy would start before the
> file is ready to be copied.

True. You could work around that by using a script instead of plain
'cp', or by making sure that no partial files appear in the archive in
the other end.

Or we could check for the partial WAL file case in the server. But
Windows copy command is worse than that, and sets the file size before
finishing copying.

From a user point-of-view, it might be simplest to provide a
"restore_directory" option, besides restore_command, and handle the copy
ourselves.

--
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2010-01-26 12:03:25 Re: Review: listagg aggregate
Previous Message Alastair Turner 2010-01-26 11:44:34 Re: Review: listagg aggregate