Skip site navigation (1) Skip section navigation (2)

Re: Block size with pg_dump?

From: Jean-David Beyer <jeandavid8(at)verizon(dot)net>
To: pgsql-sql(at)postgresql(dot)org
Subject: Re: Block size with pg_dump?
Date: 2007-08-27 12:28:25
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-sql
Hash: SHA1

Bruce Momjian wrote:
> Erik Jones wrote:
>>>>> On the way back, likewise I could pipe the tape through dd before  
>>>>> giving it
>>>>> to pg_restore.
>>>>> Does pg_dump care what blocksize it gets? If so, what is it?
>>>> I assume you could pipe pg_dump into dd and specify the block size in
>>>> dd.
>>> Of course on the way out I can do that.
>>> 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?

- --
  .~.  Jean-David Beyer          Registered Linux User 85642.
  /V\  PGP-Key: 9A2FC99A         Registered Machine   241939.
 /( )\ Shrewsbury, New Jersey
 ^^-^^ 08:25:01 up 18 days, 11:47, 2 users, load average: 4.34, 4.31, 4.27
Version: GnuPG v1.4.5 (GNU/Linux)
Comment: Using GnuPG with CentOS -


In response to


pgsql-sql by date

Next:From: Bruce MomjianDate: 2007-08-27 12:33:25
Subject: Re: Block size with pg_dump?
Previous:From: ashok rajDate: 2007-08-27 12:05:20
Subject: SQL function

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group