Received: from localhost (maia-5.hub.org [200.46.204.182]) by postgresql.org (Postfix) with ESMTP id 7FDC49F9E9C for ; Mon, 27 Aug 2007 09:33:32 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.182]) (amavisd-maia, port 10024) with ESMTP id 90625-04 for ; Mon, 27 Aug 2007 09:33:22 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from momjian.us (momjian.us [70.90.9.53]) by postgresql.org (Postfix) with ESMTP id 62B489F9E37 for ; Mon, 27 Aug 2007 09:33:27 -0300 (ADT) Received: (from bruce@localhost) by momjian.us (8.11.6/8.11.6) id l7RCXP003515; Mon, 27 Aug 2007 08:33:25 -0400 (EDT) From: Bruce Momjian Message-Id: <200708271233.l7RCXP003515@momjian.us> Subject: Re: Block size with pg_dump? In-Reply-To: <46D2C369.7040806@verizon.net> To: Jean-David Beyer Date: Mon, 27 Aug 2007 08:33:25 -0400 (EDT) CC: pgsql-sql@postgresql.org X-Mailer: ELM [version 2.4ME+ PL123] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="US-ASCII" X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200708/218 X-Sequence-Number: 29156 Jean-David Beyer wrote: > >>> The main question is, If I present pg_restore with a 65536-byte > >>> blocksize > >>> and it is expecting, e.g., 1024-bytes, will the rest of each block get > >>> skipped? I.e., do I have to use dd on the way back too? And if so, > >>> what > >>> should the blocksize be? > >> Postgres (by default) uses 8K blocks. > > > > That is true of the internal storage, but not of pg_dump's output > > because it is using libpq to pull rows and output them in a stream, > > meaning there is no blocking in pg_dumps output itself. > > > Is that true for both input and output (i.e., pg_restore and pg_dump)? > I.e., can I use dd to write 65536-byte blocks to tape, and then do nothing > on running pg_restore? I.e., that pg_restore will accept any block size I > choose to offer it? Yes. -- Bruce Momjian http://momjian.us EnterpriseDB http://www.enterprisedb.com + If your life is a hard drive, Christ can be your backup. +