Re: [PATCHES] odd output in restore mode

From: "Heikki Linnakangas" <heikki(at)enterprisedb(dot)com>
To: "Andrew Dunstan" <andrew(at)dunslane(dot)net>
Cc: "Greg Smith" <gsmith(at)gregsmith(dot)com>, "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>, "Simon Riggs" <simon(at)2ndquadrant(dot)com>, "Bruce Momjian" <bruce(at)momjian(dot)us>, "Dave Page" <dpage(at)pgadmin(dot)org>, "PostgreSQL-development" <pgsql-hackers(at)postgresql(dot)org>, "List pgsql-patches" <pgsql-patches(at)postgresql(dot)org>, "Martin Zaun" <Martin(dot)Zaun(at)Sun(dot)COM>
Subject: Re: [PATCHES] odd output in restore mode
Date: 2008-07-29 14:27:23
Message-ID: 488F28CB.8000201@enterprisedb.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

Andrew Dunstan wrote:
>
>
> Greg Smith wrote:
>> On Wed, 23 Jul 2008, Kevin Grittner wrote:
>>
>>> In our scripts we handle this by copying to a temp directory on the
>>> same mount point as the archive directory and doing a mv to the
>>> archive location when the copy is successfully completed. I think
>>> that this even works on Windows. Could that just be documented as a
>>> strong recommendation for the archive script?
>>
>> This is exactly what I always do. I think the way cp is shown in the
>> examples promotes what's really a bad practice for lots of reasons,
>> this particular problem being just one of them.
>>
>> I've been working on an improved archive_command shell script that I
>> expect to submit for comments and potential inclusion in the
>> documentation as a better base for other people to build on. This is
>> one of the options for how it can operate. It would be painful but not
>> impossible to convert a subset of that script to run under Windows as
>> well, at least enough to cover this particular issue.
>
> A Perl script using the (standard) File::Copy module along with the
> builtin function rename() should be moderately portable. It would to be
> nice not to have to maintain two scripts.

It's also not very nice to require a Perl installation on Windows, just
for a replacement of Copy. Would a simple .bat script work?

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

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Magnus Hagander 2008-07-29 14:41:55 Location of ident code
Previous Message Stephen R. van den Berg 2008-07-29 14:03:52 Re: Relicensed and downloadable (Re: Protocol 3, Execute, maxrows to return, impact?)

Browse pgsql-patches by date

  From Date Subject
Next Message David Fetter 2008-07-30 04:21:39 Re: WITH RECUSIVE patches 0723
Previous Message Pavel Stehule 2008-07-29 06:42:51 Re: WITH RECUSIVE patches 0723