Robin Walker robin
Wed Aug 25 18:07:48 PDT 2004
hello,

i’m having trouble running the first example script
transcribed within “slony-I-basic-mstr-slv.txt”.
thanks to Alan Hodgson for helping clear up an earlier
question.  my input script to slonik now looks like
this:

cluster name = pcireload_cluster9;
node 1 admin conninfo = 'dbname=pcireload
host=192.168.46.12 user=postgres';
node 2 admin conninfo = 'dbname=pcireload_slave
host=192.168.46.6 user=postgres';
init cluster ( id=1, comment = 'Master Node');
table add key (node id = 1, fully qualified name =
'public.bol');
create set (id=1, origin=1, comment='All pgbench
tables');
set add table (set id=1, origin=1, id=1, fully
qualified name = 'public.bol', comment='bol table');
store node (id=2, comment = 'Slave node');
store path (server = 1, client = 2,
conninfo='dbname=pcireload host=192.168.46.12
user=postgres');
store path (server = 2, client = 1,
conninfo='dbname=pcireload_slave host=192.168.46.6
user=postgres');
store listen (origin=1, provider = 1, receiver =2);
store listen (origin=2, provider = 2, receiver =1);

“public.bol” is just the first of 37 tables in the db,
however i’m only starting with one table to make
things simpler for my first try at this.  upon running
slonik with the above as an infile, i receive this
error message:

bash-2.05$ slonik < slonik.in
<stdin>:7: PGRES_FATAL_ERROR select
"_pcireload_cluster9".determineIdxnameUnique('public.bol',
NULL);  - ERROR:  Slony-I: table public.bol has no
primary key

however i DO have a primary key defined in public.bol:

pcireload_slave=# \d bol
                        Table "public.bol"
         Column          |            Type            
| Modifiers
-------------------------+-----------------------------+-----------
 bol_number              | integer                    
| not null
 bol_datetime            | timestamp without time zone
|
 shipping_comments       | character(255)             
|
 archived_yet            | character(1)               
|
 orphaned                | character(1)               
|
 reprinted               | character(1)               
|
 bol_type                | character(1)               
|
 pre_paid_truckload_car  | character(21)              
|
 bol_user                | character(12)              
|
 ship_to_party_name      | character(50)              
|
 ship_to_party_po_number | character(15)              
|
 rolling                 | character(1)               
|
Indexes:
    "bol_pkey" primary key, btree (bol_number)
    "bol_pk" unique, btree (bol_number)

in fact, i first ran the infile with the “table add
key...” line commented out, assuming that was not
necessary given i already had a primary key defined,
as well as without the second “bol_pk” constraint
defined.  then i un-uncommented the “table add key...”
line – same error message.  then i added the “bol_pk”
constraint just as a stab in the dark – same exact
error message.

does anyone know why i’m getting this error mesage?

much thanks,

-robin

p.s. – i seem to have to change the name of the
cluster every time i try to re-run my slonik infile
script ... otherwise it gives me the error message: 

<stdin>:4: Error: namespace "_pcireload_cluster1"
already exists in database of node 1

which, doesn’t bother me but, should be noted here.  i
presumed that since the script failed, i would be abe
to re-run the script with the same cluster name, but i
can not.  thank you.


More information about the Slony1-general mailing list