From: Scott Marlowe <smarlowe@g2switchworks.com>
To: mcelroy, tim <tim.mcelroy@bostonstock.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Ruairi <rcarroll@bluemetrix.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: Restore of pg_dump taking a long time...
Date: Wed, 24 May 2006 14:00:10 -0500
Message-ID: <1148497210.25526.22.camel@state.g2switchworks.com> (raw)
In-Reply-To: <9765373733A7DF4681B12225D2FC44050D6CE9@bosexprod001.bostonstock.local>
References: <9765373733A7DF4681B12225D2FC44050D6CE9@bosexprod001.bostonstock.local>
On Wed, 2006-05-24 at 13:56, mcelroy, tim wrote:
> I have found that the following steps have increased the speed of my
> restores:
> 1. dropdb <DBNAME>
> 2. createdb <DBANME>
> 3. Increase maintenance_work_mem as Tom mentioned. I do this at
> restore/runtime
> 4. Increase work_mem as Tom mentioned. I do this at restore/runtime
> 5. renice -20 -p <pid #> (on a Linux box) <= This step can be
> performed while the restore is running but you need root privilege
Note that if there's no other data in the database that you need to
worry about, you can also restore with fsync off. I.e. if a database
cluster could just be re-inited should a power failure occur.
If you've got already important data you can't afford to lose in the
cluster, then do not turn off fsync.
Also, remember to turn it back on before you go into production.
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: smarlowe@g2switchworks.com, tim.mcelroy@bostonstock.com, tgl@sss.pgh.pa.us, rcarroll@bluemetrix.com
Subject: Re: Restore of pg_dump taking a long time...
In-Reply-To: <1148497210.25526.22.camel@state.g2switchworks.com>
References: <9765373733A7DF4681B12225D2FC44050D6CE9@bosexprod001.bostonstock.local> <1148497210.25526.22.camel@state.g2switchworks.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