Received: from makus.postgresql.org ([98.129.198.125]) by malur.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1T70qb-0008Rq-2Y for pgsql-docs@postgresql.org; Thu, 30 Aug 2012 09:15:33 +0000 Received: from mail-lpp01m010-f46.google.com ([209.85.215.46]) by makus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1T70qZ-00051h-Ql for pgsql-docs@postgresql.org; Thu, 30 Aug 2012 09:15:32 +0000 Received: by lagy9 with SMTP id y9so1393482lag.19 for ; Thu, 30 Aug 2012 02:15:30 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:x-gm-message-state; bh=CMzKLqMNA2m9qZX7r2R6n/T8juk9b3AhfeDd/zs1ugc=; b=YW2i+RvexBWn5b90+AsndIr8+3wrdZycHS3ZFlMLKNZRbHN73Bc4WyZAPBt/2wzBpb V3AFx24ZQGbFdDSnX4eM44+QMyJZ3ud7/ym6NihXBqyEwQ1xJ1LUEJ0yLbUaIxpgmcjA EizQSqiGwpVdQE9i5UJjBRU1s9EYNlCzirlDHWE30FclJ3Qg+W3GO6VgXMZ8M+MMJMat dx8UdWpSUXpclq4adrasYthNfFWuwlUJhZ4H5XN4LmQ9UPPzLeyL/wi5FSbVUPqm3U2O dGcM7ztuMXdvmf45KZ+lOBxqmKKenukpxzw2u1Wal9K6yJl0xNrVuZKle28S+Ge8NTVS lSnQ== MIME-Version: 1.0 Received: by 10.112.82.66 with SMTP id g2mr1131396lby.15.1346318130377; Thu, 30 Aug 2012 02:15:30 -0700 (PDT) Received: by 10.152.12.132 with HTTP; Thu, 30 Aug 2012 02:15:30 -0700 (PDT) In-Reply-To: <1346291848.17422.11.camel@vanquo.pezone.net> References: <4E794FB5.80400@2ndQuadrant.com> <1316613536.14119.6.camel@fsopti579.F-Secure.com> <4E7A6D0D.4060106@2ndQuadrant.com> <4E7A887F.8010908@timbira.com> <20120816011347.GF8353@momjian.us> <502EA0D0.10004@gmx.net> <20120825230755.GE10814@momjian.us> <20120825234026.GG10814@momjian.us> <1346039025.5873.16.camel@vanquo.pezone.net> <20120827134641.GD11088@momjian.us> <1346291848.17422.11.camel@vanquo.pezone.net> Date: Thu, 30 Aug 2012 11:15:30 +0200 Message-ID: Subject: Re: somewhat wrong archive_command example From: Magnus Hagander To: Peter Eisentraut Cc: Bruce Momjian , Josh Kupershmidt , Greg Smith , Euler Taveira de Oliveira , pgsql-docs@postgresql.org Content-Type: text/plain; charset=ISO-8859-1 X-Gm-Message-State: ALoCoQlEqedvgx9LQhk19VAreg9QcB+OlM4REWW7tFc+l83vY0XBAVm3t3H6l5y8F9n6pQTeFRBI X-Pg-Spam-Score: -2.6 (--) X-Archive-Number: 201208/50 X-Sequence-Number: 7443 On Thu, Aug 30, 2012 at 3:57 AM, Peter Eisentraut wrote: > On Mon, 2012-08-27 at 09:46 -0400, Bruce Momjian wrote: >> I thought the idea was just to show what a shell script might look like >> --- we could say it does the same as a single-line copy, but then people >> could improve it, or we could add a comment to show how people could >> improve it. > > Why can't we provide the improved version to begin with, if we know it > needs improvement? I think we don't really know what it should look > like, do we? +1. >> > I think what we should do is write a wrapper program in C that covers >> > all the bases, support all platforms, and supports a handful of the most >> > commonly used copy methods (cp, scp, etc. + compression). Then everyone >> > can just use that and doesn't have to figure all these things out from >> > scratch every time. >> >> I doubt it would work because people like the flexibility of shell >> scripts. > > Well, we thought that about the base backup, but now we have > pg_basebackup, which supports two output methods that should cover most > cases. If we could provide an archive command that has two or three > methods, that could also cover most uses. Of course, in either case you > are free to write your own script. I would say the majority of people *don't* like the flexibility of shellscripts. They want something simple to use. pg_receivexlog on 9.2 is going to help some of them (as a completement to pg_basebackup). But also shipping something to use for archive_command that just copies the files in a proper way would definitely help for usability. As long as we keep the write-your-own-script-however-you-like method, just like we did for pg_basebackup, doing this can only be an improvement. And I don't see anybody suggesting we *remove* this capability. -- Magnus Hagander Me: http://www.hagander.net/ Work: http://www.redpill-linpro.com/