From: | Andrew Sullivan <andrew(at)libertyrms(dot)info> |
---|---|
To: | pgsql-general <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: Migrating database (7.1.3 - 7.2.1) |
Date: | 2002-07-25 18:35:20 |
Message-ID: | 20020725143520.V29680@mail.libertyrms.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Thu, Jul 25, 2002 at 01:32:17PM -0400, Johnson, Shaunn wrote:
>
> * Stop the database
> * pg_dump the entire database
You can't do this. You can only do pg_dump while postgres is
running.
If you have enough disk space to double your use, then you don't have
to save the pg_dump file: you could run two back ends (one on port
5432, the other on, say, 5234) and just do
pg_dump -p 5432 [your 7.1 db] | psql -p 5234 [your 7.2 db]
That _should_ work (it's worked so far for me).
If that won't work for you, pipe your pg_dump output through gzip.
Then, stop the database, tar up the data directory (using your
compressor of choice, if you like), and download that to another
location for safekeeping. Check it twice to make sure it works! Now
(here's the scary bit) delete the old tree, create a new tree, and
run the pg_dump output file back into the new (7.2) tree. This way,
if something terrible happens, you can just re-upload your tarball,
untar it in place, and start up like you never tried the upgrade.
A
--
----
Andrew Sullivan 87 Mowat Avenue
Liberty RMS Toronto, Ontario Canada
<andrew(at)libertyrms(dot)info> M6K 3E3
+1 416 646 3304 x110
From | Date | Subject | |
---|---|---|---|
Next Message | Andrew Sullivan | 2002-07-25 18:36:40 | Re: Error while dropping a table |
Previous Message | Elielson Fontanezi | 2002-07-25 18:33:49 | little shell script |