Andrew Sullivan ajs at crankycanuck.ca
Tue Aug 26 06:43:22 PDT 2008
On Tue, Aug 26, 2008 at 02:39:16PM +0800, Phoenix Kiula wrote:
> 
> 1. Install Slony

Follow the instructions available from slony.info.  They're not short,
but they're complete.  You will need to be patient and read the
documentation.  Slony is a complicated beast with lots of pointy
edges.  Sorry.
 
> 2. Install PG 8.3.3, and make sure it is working with same settings in
> "pg_hba.conf" and "postgresql.conf" as my current working db

It can't have the same settings exactly, because the 8.3 and 8.2
releases are different, and therefore need different tuning.  Install 8.3
on your machine and run it on a different port.  If you are running
a Debian-based distribution of Linux, you can install from packages.
Otherwise, you'll need to do this from source, because most other
distributions make it hard to run multiple versions.  How to configure
the pg_hba.conf is explained in painful detail in the postgres manual,
and you'll have to read how to do it there.
 
> 3. Replicate my current working db of PG 8.2.3 to this new installed
> 8.3.3 using Slony? (I am not familiar with master and slave stuff, so
> simple instructions would be nice)

Sorry, you _need_ to read the introductory material in Slony's manual.
The "simple instructions" you seek won't help you.  It's just not a
simple system, because this isn't all it was designed to do.
 
> 4. When all data is replicated and working, just switch the master and
> slave, so that the new 8.3.3 becomes the main database

This is easy, in Slony terms, but still puzzling if you know nothing
about Slony.  You use a slonik script to perform a switchover,
pointing the origin of all data sets from the 8.2 installation to the
8.3 installation.  This has the additional benefit that the 8.2 system
becomes a replica, so that if things blow up after you come up on 8.3
(you tested 8.3, right?  There are big changes in 8.3, and things that
used to work sometimes have stopped working ever in order to solve a
class of bugs that were obscured by the "sometimes"), you can switch
back (i.e. you get a "rollback plan").
 
> Are there any simple straightforward instructions for this that don't
> assume that I'm a super techsavvy DBA with 300 years of experience?

Yes, but there aren't any that don't require you read a lot of
material and understand it.  You have to become a reasonably competent
Postgres dba.  If you want something as simple as a filesystem, you
need not to use Postgres.

If this is too difficult or time-consuming for you, you could pay
someone (my employer, for instance) to help you with this.

A

-- 
Andrew Sullivan
ajs at commandprompt.com
+1 503 667 4564 x104
http://www.commandprompt.com/


More information about the Slony1-general mailing list