Pradeep Parmar parmarpradeep
Thu Nov 23 04:36:32 PST 2006
Hi,

I was trying setting up slony on two diff. nodes. Node A as master server
and Node B as slave
Database has just two tables , one of the tables doesn't has a primary key
so i have used the table add key in the slonik commands script. I'm getting
the below error


<stdin>:7: PGRES_FATAL_ERROR select "_slash".determineIdxnameUnique('
public.staff', NULL);  - ERROR:  Slony-I: table "public"."staff" has no
primary key


Script looks like this :

> cluster name = $CLUSTERNAME;
> node 1 admin conninfo = 'dbname=$MASTERDBNAME host=$MASTERHOST
user=$REPLICATIONUSER';
>  node 2 admin conninfo = 'dbname=$SLAVEDBNAME host=$SLAVEHOST
user=$REPLICATIONUSER';
>  init cluster ( id=1, comment = 'Master Node');
> table add key (node id = 1, fully qualified name = 'public.staff');table
add key (node id = 1, fully qualified name = 'public.staff');
> create set (id=1, origin=1, comment='All tables');
> set add table (set id=1, origin=1, id=1, fully qualified name = '
public.staff', comment='staff table');
> set add table (set id=1, origin=1, id=1, fully qualified name = '
public.emp', comment='emp table');
> store node (id=2, comment = 'Slave node');
> store path (server = 1, client = 2, conninfo='dbname=$MASTERDBNAME
host=$MASTERHOST user=$REPLICATIONUSER');
> store path (server = 2, client = 1, conninfo='dbname=$SLAVEDBNAME
host=$SLAVEHOST user=$REPLICATIONUSER');
> store listen (origin=1, provider = 1, receiver =2);
> store listen (origin=2, provider = 2, receiver =1);

Please help me out in this...

Rgds
-- 
Pradeep Parmar
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gborg.postgresql.org/pipermail/slony1-general/attachments/20061123/888b269a/attachment.html 



More information about the Slony1-general mailing list