Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 22C8F475AD7 for ; Sat, 18 Jan 2003 11:20:22 -0500 (EST) Received: from mailsrv.otenet.gr (mailsrv.otenet.gr [195.170.0.5]) by postgresql.org (Postfix) with ESMTP id 2A78C474E5C for ; Sat, 18 Jan 2003 11:20:21 -0500 (EST) Received: from mail.otenet.gr (roba.otenet.gr [195.170.0.17]) by mailsrv.otenet.gr (8.12.6/8.12.6) with ESMTP id h0IGKOSa022060 for ; Sat, 18 Jan 2003 18:20:24 +0200 (EET) Received: from confuzio (athei36-a020.otenet.gr [62.103.177.20]) by mail.otenet.gr (8.12.6/8.12.6) with ESMTP id h0IGKNAs029327 for ; Sat, 18 Jan 2003 18:20:23 +0200 (EET) Content-Type: text/plain; charset="us-ascii" From: Alexandros Perdikomatis Organization: UNKNOWN ORGANIZATION To: pgsql-interfaces@postgresql.org Subject: Database backup Date: Sat, 18 Jan 2003 16:17:24 +0200 User-Agent: KMail/1.4.3 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Message-Id: <200301181617.24700.menippos@otenet.gr> X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200301/79 X-Sequence-Number: 3579 Hello everybody! I use postgresql for long time now, all through libpq (wich I think is the= =20 most exciting interface) and everything is fine. When I wanted to backup the base, I was using: "pg_dump mybase > mybase.pgd" and "cat mybase.pgd|psql mybase" (don't care about OIDs) I faced some small problems to finalise the conversion settings between=20 different versions, but at the end everything was fine. Question: Am I too stupid to use tar? Some time I had no space on the filesystem to copy all the data in command= =20 mode (pg_dump) so I thought to pipe pg_dump to tar using a scsi tape archiv= er=20 as output (/dev/rmt0). Why doesn't work? Using just pg_dump we have the output to stdout. I thought that I missender a parameter or something. If this is the case, sorry everybody for bothering - I'm just too stupid to= =20 use the pipe to tar. In this case, PLEASE someone drop a line correcting th= e=20 syndax for me. If is not, then we have to thing about piping pg_dump to tape archive. //a command line view: # pg_dump mybase|tar cvf /dev/rmt0 - // (and some other versions) tar: -: Cannot stat: No such file or directory tar: Error exit delayed from previous errors # tar xvf /dev/rmt0|psql mybase EOF // (!!!) # after the "EOF" message from psql the database is, of cource, empty. ***************** thanks, Alexandros