Re: How do you upgrade for production servers? - Mailing list pgsql-admin

From Phillip Smith
Subject Re: How do you upgrade for production servers?
Date
Msg-id 200612300002.26510.fukawi2@iinet.net.au
Whole thread Raw
In response to How do you upgrade for production servers?  (Arnau <arnaulist@andromeiberica.com>)
List pgsql-admin
I install the new version to a new directory (eg, /usr/local/pg-8.2 ) then
start that server on a different port to the live server (eg, 54321), create
a new data directory (eg. /home/postgres/pgData-8.2) dump the live database,
import to the new database to make sure it's all good, then once I know
that's all good, I'll drop the live database back to "single user mode" using
pg_hba.conf, dump the database again, shutdown the old version, restart the
new version on the normal port, re-import the data then re-enable normal
access with pg_hba.conf

I have the advantage that our database generally isn't  accessed out of
 hours, so I have the luxury to be able to have the server offline for 30 -
 60 minutes while the second dump and import is happening. Depends how big
 your database is as to how long the server will be unavailable.

At least by installing the new version to a new directory and doing a test
import first lets me see how (if) the new version will affect the data
without having the live server offline.

Cheers,
-p

On Friday 29 December 2006 23:06, Arnau wrote:
> Hi all,
>
>    This is a general question about which procedure you follow when you
> upgrade your productions servers. Let's say we have a server running and
> older version and I want to install the latest version on the same
> server. Do you install slony? do you dump all the databases, install the
> latest version and after you restore? any other procedure? I'd like to
> have my production server down as less time as possible.
>
>
> Thank you very much and have a great new year :D

-------------------------------------------------------

pgsql-admin by date:

Previous
From: Olivier Boissard
Date:
Subject: table comparison
Next
From: "Andy Shellam (Mailing Lists)"
Date:
Subject: Re: Postgres and Firewall