pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Joseph McClintock <joe.mcclintock@antics.com>
To: pgsql-admin@postgresql.org
Subject: Very Very Slow Database Restore
Date: Wed, 20 Dec 2006 12:34:20 -0800
Message-ID: <1166646860.3941.4.camel@mcclintock.anticsoffline.com> (raw)

I have inherited the on going management of our company's PostgreSQL 8.0
database. I'm having a very serious problem with the restore process.
I've been running periodic pg_dumps from our production database and
then restoring the data on our development system. That has been working
find until now. Previously when I ran:


pg_dump -U username database > db.backup


I would get me a 800+ MB file and I could restore with


psql -U username -d database < db.backup


which took 15 minutes or so.


Now our database has grown and the pg_dump give me a 2.1 GB file which
is taking 12 hours or more to restore, Yickes! I've tried compressing
the dump file:


pg_dump -F c -U username database > db.backup 


and then run 


pg_restore -U username -d database db.backup


but no difference and probably its slower because the restore has to
decompress the dump.


The database configuration is pretty much out of the box. The only thing
that's been changed is the number of allowed db connections which I
don't think has much barring on this problem.


Any thoughts about this problem would be appreciated. 

Thanks




view thread (4+ messages)  latest in thread

Message-ID: <1166646860.3941.4.camel@mcclintock.anticsoffline.com>
Permalink:  ../1166646860.3941.4.camel@mcclintock.anticsoffline.com/
Also on:    postgresql.org/message-id/1166646860.3941.4.camel@mcclintock.anticsoffline.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: joe.mcclintock@antics.com
  Subject: Re: Very Very Slow Database Restore
  In-Reply-To: <1166646860.3941.4.camel@mcclintock.anticsoffline.com>
  References: <1166646860.3941.4.camel@mcclintock.anticsoffline.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox