Enterprise Replication Problems on Linux Redhat 6.1
Posted in 2000
Topics: High Availability & Replication, Connectivity: ODBC / JDBC / .NET, Security, Permissions & Auditing, Logging & Checkpoints, Networking & sqlhosts Configuration, Platform-Specific Issues
I am having major trouble getting ER to work for Informix 9.21 under
Redhat Linux 6.1 I've opened a case with Informix, but am looking for
some help from someone who's actually replicated under Linux before.
I have setup 3 machines JEFF, MOE, LISA to replicate in UPDATE ANYWHERE
mode a table called USER_OBJECTS. I'm just following instructions from
the Guide to Informix Enterprise Replication, Replication
Examples page 3-9 for the Update Anywhere example.
My setup looks like this:
SQL HOST FILE ON ALL MACHINES:
-----------------------------
g_lisa group - - i=1
gigalisa onsoctcp lisa.gigaton.com informixjdbc
g=g_lisa
shmlisa onipcshm lisa.gigaton.com unique
g=g_lisa
jdbclisa onsoctcp lisa.gigaton.com informixjdbc
g=g_lisa
g_jeff group - - i=2
gigajeff onsoctcp 10.10.10.122 informixjdbc
g=g_jeff
g_moe group - - i=3
gigamoe onsoctcp moe.gigaton.com informixjdbc
g=g_moe
Replication Setup
--------------
cdr define server --init g_moe
cdr define server --connect=gigajeff --init --sync=g_moe g_jeff
cdr define server --connect=gigalisa --init --sync=g_moe g_lisa
cdr define replicate --conflict=ignore user_objects \\
"gigameta@g_moe:informix.user_objects" "select * from user_objects" \\
"gigameta@g_jeff:informix.user_objects" "select * from user_objects" \\
cdr change replicate --add user_objects \\
"gigameta@g_lisa:informix.user_objects" "select * from user_objects"
cdr start replicate user_objects
cdr list replicate user_objects
REPLICATE SERVER STATE TABLE
SELECT
----------------------------------------------------------------------------
user_objects g_moe ACTIVE user_objects
select * from user_objectsuser_objects g_jeff ACTIVE user_objects
select * from user_objectsuser_objects g_lisa ACTIVE user_objects
select * from user_objects[10:45:05][informix@moe:1031]
cdr list server
SERVER ID STATE STATUS CONNECTION CHANGED
------------------------------------------------------------------
g_jeff 2 Active Connected Mar 27 19:56:45 2000
g_lisa 1 Active Connected Mar 27 22:43:19 2000
g_moe 3 Active Local
[10:45:18][informix@moe:1032]
SQL EXECUTED
-------------
begin work;
insert into objects values ('spiderman',1);
insert into user_objects (username,password,oid,usedspace) values
('spiderman','spiderman','spiderman','1');
commit work;
ERROR MESSAGE RECEIVED ON TWO MACHINE LOG FILES
--------------------------------------------------
Tue Mar 28 10:38:22 2000
10:38:22 CDR CDRDS: transaction aborted (Error return from SQL for thecommit command)
10:38:28 Checkpoint Completed: duration was 0 seconds.
10:38:28 Checkpoint loguniq 53, logpos 0x25b018
10:43:27 Checkpoint Completed: duration was 0 seconds.
10:43:27 Checkpoint loguniq 53, logpos 0x25c018
I don't see any error messages for ATS/RIS either, only the above
message. Doe anyone know why this is occurring?
The transaction commits on the server I'm running the SQL from, but is
not replicated to the other two servers.
Any help would be appreciated.
Thanks,
Jeff
Sent via Deja.com http://www.deja.com/
Before you buy.
Do you have a FK from user_objects to objects? Also, the reason you did not see any ATS/RIS entries
is that you did not specify directories on your cdr define server statement. Redefine your servers
and add the --ats,--ris to your replicate definition.
Alan
jeffhazelwood@my-deja.com wrote:
> I am having major trouble getting ER to work for Informix 9.21 under
> Redhat Linux 6.1 I've opened a case with Informix, but am looking for
> some help from someone who's actually replicated under Linux before.
>
> I have setup 3 machines JEFF, MOE, LISA to replicate in UPDATE ANYWHERE
> mode a table called USER_OBJECTS. I'm just following instructions from
> the Guide to Informix Enterprise Replication, Replication
> Examples page 3-9 for the Update Anywhere example.
>
> My setup looks like this:
>
> SQL HOST FILE ON ALL MACHINES:
> -----------------------------
> g_lisa group - - i=1
> gigalisa onsoctcp lisa.gigaton.com informixjdbc
> g=g_lisa
> shmlisa onipcshm lisa.gigaton.com unique
> g=g_lisa
> jdbclisa onsoctcp lisa.gigaton.com informixjdbc
> g=g_lisa>
> g_jeff group - - i=2
> gigajeff onsoctcp 10.10.10.122 informixjdbc
> g=g_jeff>
> g_moe group - - i=3
> gigamoe onsoctcp moe.gigaton.com informixjdbc
> g=g_moe>
> Replication Setup
> --------------
>
> cdr define server --init g_moe
> cdr define server --connect=gigajeff --init --sync=g_moe g_jeff
> cdr define server --connect=gigalisa --init --sync=g_moe g_lisa
>
> cdr define replicate --conflict=ignore user_objects \\
> "gigameta@g_moe:informix.user_objects" "select * from user_objects" \\
> "gigameta@g_jeff:informix.user_objects" "select * from user_objects" \\
>
> cdr change replicate --add user_objects \\
> "gigameta@g_lisa:informix.user_objects" "select * from user_objects"
>
> cdr start replicate user_objects
> cdr list replicate user_objects
> REPLICATE SERVER STATE TABLE
> SELECT
> ----------------------------------------------------------------------------
> user_objects g_moe ACTIVE user_objects
> select * from user_objects> user_objects g_jeff ACTIVE user_objects
> select * from user_objects> user_objects g_lisa ACTIVE user_objects
> select * from user_objects> [10:45:05][informix@moe:1031]
>
> cdr list server
> SERVER ID STATE STATUS CONNECTION CHANGED
> ------------------------------------------------------------------
> g_jeff 2 Active Connected Mar 27 19:56:45 2000
> g_lisa 1 Active Connected Mar 27 22:43:19 2000
> g_moe 3 Active Local
> [10:45:18][informix@moe:1032]
>
> SQL EXECUTED
> -------------
>
> begin work;
>
> insert into objects values ('spiderman',1);>
> insert into user_objects (username,password,oid,usedspace) values
> ('spiderman','s> piderman','spiderman','1');
>
> commit work;
>
> ERROR MESSAGE RECEIVED ON TWO MACHINE LOG FILES
> --------------------------------------------------
> Tue Mar 28 10:38:22 2000
>
> 10:38:22 CDR CDRDS: transaction aborted (Error return from SQL for the> commit command)
> 10:38:28 Checkpoint Completed: duration was 0 seconds.
> 10:38:28 Checkpoint loguniq 53, logpos 0x25b018
>
> 10:43:27 Checkpoint Completed: duration was 0 seconds.
> 10:43:27 Checkpoint loguniq 53, logpos 0x25c018>
> I don't see any error messages for ATS/RIS either, only the above
> message. Doe anyone know why this is occurring?
>
> The transaction commits on the server I'm running the SQL from, but is
> not replicated to the other two servers.
>
> Any help would be appreciated.
>
> Thanks,
>
> Jeff
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
Well, I worked with some of the Linux Platform Engineers during the testing of
9.21, so I guess that I qualify for having run 9.21 ER on the Linux platform.
The error that you are getting occurs during the commit of the DataSync
transaction on the target system. (The DataSync threads are the CDRD_###
threads.) The replay of the transaction on the target system has been
successful and is trying to commit and is running into some kind of problem.
What it is we don't know because we aren't getting the ATS/RIS files created.
If I'm correct you have opened a case (#946114) with tech support on this
problem. I entered a note in the case earlier this evening. When you talk
with Joe tomorrow, maybe you'll already be a bit further in a resolution. I'm
going to relay in this news group much of what I put into the case.
ER defers constraint checking until commit time. The reason for this is that
some of your activies in the original trasaction might be shifted just a bit on
the target instance. Therefor we do not want to run into referential
constraint violations because we shifted the the insert of the parent row after
the insert of the child. Since you are encountering the error during the
commit phase, my first guess would be that there is some type of constraint
violation which is causing the problem.
But we need evidence of the actual error that you are getting so we have some
idea as to resolve the problem.
>From the case notes, I see that you modified the server to add the ATS/RIS
directories. I'm assuming that you created this on all of the servers, that
the directory exists, and that it can be written to by user informix. Did you
also modify the replicates to include ATS/RIS spooling? To do this you would
need to execute:
cdr modify repl -A -R user_objects
(There was a bug in this command in 7.31/9.2. --ris was mispelled. You had to
enter --rts instead. I think this was corrected in 9.21.)
After you have done this, you need to run your test again and see if the error
is still occuring and if there is nothing in the ATS/RIS directories on the
target system. If there is nothing there then here's what we will need for the
case.
1) dbschema listing of the table definition on both the source and the target
instances. Be sure to include the -ss option.
2) onstat -g cat
3) From syscdr select * from the following tables:
a - repdef
b - cdr_errors
When you get this information, please pass it to the case owner. He will put
it into the case. We can proceed from there.
---------------------------------------------------------
Madison Pruet
Informix Software
Product Development - Enterprise Replication
---------------------------------------------------------
jeffhazelwood@my-deja.com wrote:
> I am having major trouble getting ER to work for Informix 9.21 under
> Redhat Linux 6.1 I've opened a case with Informix, but am looking for
> some help from someone who's actually replicated under Linux before.
>
> I have setup 3 machines JEFF, MOE, LISA to replicate in UPDATE ANYWHERE
> mode a table called USER_OBJECTS. I'm just following instructions from
> the Guide to Informix Enterprise Replication, Replication
> Examples page 3-9 for the Update Anywhere example.
>
> My setup looks like this:
>
> SQL HOST FILE ON ALL MACHINES:
> -----------------------------
> g_lisa group - - i=1
> gigalisa onsoctcp lisa.gigaton.com informixjdbc
> g=g_lisa
> shmlisa onipcshm lisa.gigaton.com unique
> g=g_lisa
> jdbclisa onsoctcp lisa.gigaton.com informixjdbc
> g=g_lisa>
> g_jeff group - - i=2
> gigajeff onsoctcp 10.10.10.122 informixjdbc
> g=g_jeff>
> g_moe group - - i=3
> gigamoe onsoctcp moe.gigaton.com informixjdbc
> g=g_moe>
> Replication Setup
> --------------
>
> cdr define server --init g_moe
> cdr define server --connect=gigajeff --init --sync=g_moe g_jeff
> cdr define server --connect=gigalisa --init --sync=g_moe g_lisa
>
> cdr define replicate --conflict=ignore user_objects \\
> "gigameta@g_moe:informix.user_objects" "select * from user_objects" \\
> "gigameta@g_jeff:informix.user_objects" "select * from user_objects" \\
>
> cdr change replicate --add user_objects \\
> "gigameta@g_lisa:informix.user_objects" "select * from user_objects"
>
> cdr start replicate user_objects
> cdr list replicate user_objects
> REPLICATE SERVER STATE TABLE
> SELECT
> ----------------------------------------------------------------------------
> user_objects g_moe ACTIVE user_objects
> select * from user_objects> user_objects g_jeff ACTIVE user_objects
> select * from user_objects> user_objects g_lisa ACTIVE user_objects
> select * from user_objects> [10:45:05][informix@moe:1031]
>
> cdr list server
> SERVER ID STATE STATUS CONNECTION CHANGED
> ------------------------------------------------------------------
> g_jeff 2 Active Connected Mar 27 19:56:45 2000
> g_lisa 1 Active Connected Mar 27 22:43:19 2000
> g_moe 3 Active Local
> [10:45:18][informix@moe:1032]
>
> SQL EXECUTED
> -------------
>
> begin work;
>
> insert into objects values ('spiderman',1);>
> insert into user_objects (username,password,oid,usedspace) values
> ('spiderman','s> piderman','spiderman','1');
>
> commit work;
>
> ERROR MESSAGE RECEIVED ON TWO MACHINE LOG FILES
> --------------------------------------------------
> Tue Mar 28 10:38:22 2000
>
> 10:38:22 CDR CDRDS: transaction aborted (Error return from SQL for the> commit command)
> 10:38:28 Checkpoint Completed: duration was 0 seconds.
> 10:38:28 Checkpoint loguniq 53, logpos 0x25b018
>
> 10:43:27 Checkpoint Completed: duration was 0 seconds.
> 10:43:27 Checkpoint loguniq 53, logpos 0x25c018>
> I don't see any error messages for ATS/RIS either, only the above
> message. Doe anyone know why this is occurring?
>
> The transaction commits on the server I'm running the SQL from, but is
> not replicated to the other two servers.
>
> Any help would be appreciated.
>
> Thanks,
>
> Jeff
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
Related threads
- Posting from the Informix-list
- Migrating from IDS 9.40.UC6 to 11.50.UC3
- Ip for a network session
- questions onstat -g