pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Christopher Browne <cbbrowne@ca.afilias.info>
To: pgsql-novice@postgresql.org
Subject: Re: slony replication
Date: Mon, 20 Dec 2004 18:31:04 -0500
Message-ID: <60r7lkbl8n.fsf@dba2.int.libertyrms.com> (raw)
References: <20041220222526.74532.qmail@web51308.mail.yahoo.com>

sarlavk@yahoo.com (sarlav kumar) writes:
> I installed slony1.0.5 and tried the example replication of pgbench
> database. That seemed to work. Now I need to replicate a DB running
> on a different server. slony1.0.5 is installed on the Fedora core 3
> machine where Postgres 7.4.6 is installed. I have to replicate the
> 'test' database installed on a different machine using Postgres
> 7.3.2.

Slony-I does not support versions of PostgreSQL earlier than 7.3.3.
As 7.3.2 is earlier than 7.3.3, I wouldn't expect that to work.

> In the instructions to replicate the pgbench example, there is
> script file to create the initial configuration for the master-slave
> setup of the pgbench database. Is this the script file that has to
> be modified accordingly, to replicate my 'test' DB. And ofcourse,
> the shell variables have to be changed to indicate the correct
> location of the master and slave DBs. Am I right?

Yes, that would be right.

> Also, in the script, the following lines are used to create sets of tables:
>
> # Slony-I organizes tables into sets.  The smallest unit a node can
>     # subscribe is a set.  The following commands create one set containing
>     # all 4 pgbench tables.  The master or origin of the set is node 1.
> #--
> create set (id=1, origin=1, comment='All pgbench tables');
> set add table (set id=1, origin=1, id=1, fully qualified name = 'public.accounts', comment='accounts table');
> set add table (set id=1, origin=1, id=2, fully qualified name = 'public.branches', comment='branches table');
> set add table (set id=1, origin=1, id=3, fully qualified name = 'public.tellers', comment='tellers table');
> set add table (set id=1, origin=1, id=4, fully qualified name = 'public.history', comment='history table', key =
> serial);
> #--
>
> Can this be skipped? I have over 200 tables, and I am not sure if I
> have to list each of them in the "set add table" part of the scripts
> file.

No, you cannot "skip" this.  You _must_ submit slonik requests to add
each and every table that you wish to replicate to the replication
set.

If there are 220 tables, you'll need something rather close to 220
"set add table" requests.

> Do I need to change any of the other scripts file in the example?

Maybe, depending on what you're trying to do.
-- 
"cbbrowne","@","ca.afilias.info"
<http://linuxdatabases.info/info/slony.html;
Christopher Browne
(416) 673-4124 (land)



view thread (3+ messages)  latest in thread

Message-ID: <60r7lkbl8n.fsf@dba2.int.libertyrms.com>
Permalink:  ../60r7lkbl8n.fsf@dba2.int.libertyrms.com/
Also on:    postgresql.org/message-id/60r7lkbl8n.fsf@dba2.int.libertyrms.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 using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: cbbrowne@ca.afilias.info, pgsql-novice@postgresql.org
  Subject: Re: slony replication
  In-Reply-To: <60r7lkbl8n.fsf@dba2.int.libertyrms.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