solidDB Help : Replication : C Replicator : CREP Monitoring and diagnostics : Generating trace log from the replicator
  
Generating trace log from the replicator
C Replicator (CREP) replicator trace log is disabled by default, but can be enabled by running the following command in the server that hosts the replicator:
ADMIN COMMAND 'trace on crep'
Trace log is written as plain text in the same soltrace.out file that is used by other subsystems of solidDB. Replication trace includes detailed information on replication, including execution of replication commands, detailed error messages, row-level replication progress, and connections to the source database, for example, the following text shows trace log associated with the statement:
START REPLICATION SUBSCRIPTION SUB1
2022-07-13 16:32:40.004 14:crep:Connected to local server with user id 11
2022-07-13 16:32:40.019 12:crep:Starting load for subscription 'SUB1'
2022-07-13 16:32:40.019 12:crep:New subscription 'SUB1' state is LOAD.
2022-07-13 16:32:40.026 12:crep:New connection to 'tcp 1323', remote user id 11, remote time: 2022-07-13 16:32:40.026, local uuid: 269e5505-ae02-4d01-846e-4b3a2a1b58ca
2022-07-13 16:32:40.032 12:crep:Starting load for subscription SUB1 from source position 000000000000C0DCFFFFFFFF0000000000019070000000000001907C.
2022-07-13 16:32:40.099 12:crep:Starting load for subscription 'SUB1' table "DBA"."DBA"."TAB1" index 0
2022-07-13 16:32:40.109 12:crep:Load completed loading subscription 'SUB1' at position 000000000000C0DCFFFFFFFF0000000000019070000000000001907C rows count 2.
2022-07-13 16:32:40.116 12:crep:New subscription 'SUB1' state is STOPPED.
2022-07-13 16:32:45.166 12:crep:New connection to 'tcp 1323', remote user id 17, remote time: 2022-07-13 16:32:45.166, local uuid: 269e5505-ae02-4d01-846e-4b3a2a1b58ca
2022-07-13 16:32:45.169 12:crep:Close connection
2022-07-13 16:32:45.170 12:crep:Logreader open: server SUB1, partition SHARE1, logpos 000000000000C0DCFFFFFFFF0000000000019070000000000001907C
2022-07-13 16:32:46.226 12:crep:New subscription 'SUB1' state is CATCHUP.
2022-07-13 16:32:46.228 12:crep:Starting replication for subscription 'SUB1' from position 000000000000C0DCFFFFFFFF0000000000019070000000000001907C.
2022-07-13 16:32:46.239 51:crep:Logreader thread started: SUB1
2022-07-13 16:32:46.239 51:crep:New subscription 'SUB1' state is ACTIVE..
You can also trace replicator apply operations by running the following command:
ADMIN COMMAND 'trace on crepapply'
For example, the following text shows trace log associated with a transaction that inserts records:
2022-07-13 16:36:59.806 -1:crepapply:Transaction add record: 0: RecNo: 339750:DBE_LOGREADER_LOG_REC_COMMIT:trxid=202568:relid:0:logposition:0000000000017D63FFFFFFFF00000000000317180000000000031748
2022-07-13 16:36:59.872 -1:crepapply:Prepare insert: INSERT INTO "DBA"."BASIC_1"."T_BINARY_2" VALUES(?,?)
2022-07-13 16:36:59.872 -1:crepapply:Applying record: 0: RecNo: 339749:DBE_LOGREADER_LOG_REC_INSERT:trxid=202568:relid:10154:logposition:0000000000017D630000001100000000000317180000000000031748, record=0x7fd7687f97d8
2022-07-13 16:36:59.873 -1:crepapply:Applying record: 0: RecNo: 339750:DBE_LOGREADER_LOG_REC_COMMIT:trxid=202568:relid:0:logposition:0000000000017D63FFFFFFFF00000000000317180000000000031748, record=0x7fd77484a858
2022-07-13 16:36:59.874 -1:crepapply:Applying commit: 0: 0000000000017D63FFFFFFFF00000000000317180000000000031748 e=0
Messages that include Transaction add record are recorded in the trace log when the target server has received a record from the source, and messages that include Applying record are recorded when the records are applied in the target database.
Go up to
CREP Monitoring and diagnostics