Fri Jan 7 16:41:48 PST 2005
- Previous message: [Slony1-general] Does there have to be a node 1?
- Next message: [Slony1-general] Schema-Update
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hello, to replicate the databases of the company, where I work, I decided to use slony-I. I created a Perl-script to manage creation of database,replicationset and some other functionalities Following processes works fine: - creating/init cluster und store nodes - subscription of nodes - unsubscribing nodes Following processes works, but create some errors: a) complete deletion of replicationdata (unsubscribe, drop set, drop node etc.) --> after unsubscribing the nodes, the are transaction, which have to be written to the slony-tables, but "drop set" and "drop node" are reacts to fast, so the transaction won't be written anymore and an error raised up, that the replication-schema did not exists. So, how can I prevent this error? All the commands are located in 1 slonik-commandline. Should I decide to stop (unsubscribe) and later (1 minute or so) to drop the replication? b) one of our databases, which is in "replication-mode", needs a schema-update (user has recognized that a field with varchar(200) was to short) I created a SQL-File, which do the following: creates a copy of the table ALTER table RENAME tablefield TO tablefield_old; ALTER table ADD COLUMN tablefield text; UPDATE table SET tablefield = copytable.tablefield WHERE table.primkey = copytable.primkey ALTER TABLE table DROP COLUMN tablefield_old The SQL-Statements are called after an unsubscribe node(); After the SQL-statements a subscribe node () is called. The schema-update works fine, but slony-Log offers an error, that COPY fails, because the table-structure didn't fit the content of COPY anymore. Documentation about these special things is very limited and I couldn't find examples about these steps. So, can anyone help me, to solve these problems? Thanks a lot Regards Christian Michel
- Previous message: [Slony1-general] Does there have to be a node 1?
- Next message: [Slony1-general] Schema-Update
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Slony1-general mailing list