GoldenGate_Replicat_Skip_Long_Transaction
客户在ogg源端进行了一次大批量的更新操作,导致ogg应用端进程延迟过高,需要去掉此大事务操作。以下为演示
SQL> create tablespace goldengate datafile '/oradata/orcl/goldengate01.dbf' size 20m autoextend on; Tablespace created. SQL> create tablespace ogg_test datafile '/oradata/orcl/ogg_test01.dbf' size 20m autoextend on; Tablespace created. SQL> create user goldengate identified by goldengate; User created. SQL> create user ogg1 identified by ogg1 default tablespace ogg_test; User created. SQL> create user ogg2 identified by ogg2 default tablespace ogg_test; User created. SQL> alter user goldengate default tablespace ogg_test 2 ; User altered. SQL> SQL> SQL> grant dba to goldengate; Grant succeeded. SQL> grant dba to ogg1; Grant succeeded. SQL> grant dba to ogg2; Grant succeeded. SQL> quit SQL> conn ogg1/ogg1 Connected. USERNAME INST_NAME HOST_NAME SID SERIAL# VERSION STARTED SPID OPID CPID SADDR PADDR -------------------- ------------ ------------------------- ----- -------- ---------- -------- --------------- ----- --------------- ---------------- ---------------- OGG1 orcl enmotech 19 17 11.2.0.3.0 20140419 3250 32 3247 0000000084E784F8 0000000084CA5F50 SQL> create table ogg_test as select * from dba_objects; Table created. SQL> select count(*) from ogg_test; COUNT(*) ---------- 14259 SQL> insert into ogg_test select * from ogg_test; 14259 rows created. SQL> insert into ogg_test select * from ogg_test; 28518 rows created. SQL> insert into ogg_test select * from ogg_test; 57036 rows created. SQL> insert into ogg_test select * from ogg_test; 114072 rows created. SQL> insert into ogg_test select * from ogg_test; 228144 rows created. SQL> commit; Commit complete. SQL> commit; Commit complete. SQL> insert into ogg_test select * from ogg_test; 456288 rows created. SQL> insert into ogg_test select * from ogg_test; 912576 rows created. SQL> insert into ogg_test select * from ogg_test; 1825152 rows created. SQL> insert into ogg_test select * from ogg_test; 3650304 rows created. SQL> commit; ALTER TABLE ogg_test ADD CONSTRAINT ogg_test_pk PRIMARY KEY(id) USING INDEX TABLESPACE ogg_test / SQL> @desc ogg_test Name Null? Type ------------------------------- -------- ---------------------------- 1 OWNER VARCHAR2(30) 2 OBJECT_NAME VARCHAR2(128) 3 SUBOBJECT_NAME VARCHAR2(30) 4 OBJECT_ID NUMBER 5 DATA_OBJECT_ID NUMBER 6 OBJECT_TYPE VARCHAR2(19) 7 CREATED DATE 8 LAST_DDL_TIME DATE 9 TIMESTAMP VARCHAR2(19) 10 STATUS VARCHAR2(7) 11 TEMPORARY VARCHAR2(1) 12 GENERATED VARCHAR2(1) 13 SECONDARY VARCHAR2(1) 14 NAMESPACE NUMBER 15 EDITION_NAME VARCHAR2(30) 16 ID NOT NULL NUMBER
以上是模拟环境创建了一张大表,下面进行更新操作
SQL> update ogg_test set CREATED=sysdate; 7300608 rows updated. SQL> commit; Commit complete. --提交 --查看ogg 日志发现提示Long Running Transaction: XID 29.22.494 本来这里可以通过send extract EXT1, skiptrans 29.22.494 thread 1来跳过 ,但是没有操作 2014-04-19 21:32:39 WARNING OGG-01027 Oracle GoldenGate Capture for Oracle, ext1.prm: Long Running Transaction: XID 29.22.494, Items 1903861, Extract EXT1, Redo Thread 1, SCN 2.1665932 (8591600524), Redo Seq #326, Redo RBA 7945744. 2014-04-19 21:32:49 WARNING OGG-01027 Oracle GoldenGate Capture for Oracle, ext1.prm: Long Running Transaction: XID 29.22.494, Items 1903861, Extract EXT1, Redo Thread 1, SCN 2.1665932 (8591600524), Redo Seq #326, Redo RBA 7945744. 2014-04-19 21:32:59 WARNING OGG-01027 Oracle GoldenGate Capture for Oracle, ext1.prm: Long Running Transaction: XID 29.22.494, Items 3453426, Extract EXT1, Redo Thread 1, SCN 2.1665932 (8591600524), Redo Seq #326, Redo RBA 7945744. 2014-04-19 21:33:09 WARNING OGG-01027 Oracle GoldenGate Capture for Oracle, ext1.prm: Long Running Transaction: XID 29.22.494, Items 3631983, Extract EXT1, Redo Thread 1, SCN 2.1665932 (8591600524), Redo Seq #326, Redo RBA 7945744. 2014-04-19 21:33:20 WARNING OGG-01027 Oracle GoldenGate Capture for Oracle, ext1.prm: Long Running Transaction: XID 29.22.494, Items 4979126, Extract EXT1, Redo Thread 1, SCN 2.1665932 (8591600524), Redo Seq #326, Redo RBA 7945744. 2014-04-19 21:33:30 WARNING OGG-01027 Oracle GoldenGate Capture for Oracle, ext1.prm: Long Running Transaction: XID 29.22.494, Items 5594547, Extract EXT1, Redo Thread 1, SCN 2.1665932 (8591600524), Redo Seq #326, Redo RBA 7945744. 2014-04-19 21:33:40 WARNING OGG-01027 Oracle GoldenGate Capture for Oracle, ext1.prm: Long Running Transaction: XID 29.22.494, Items 6357114, Extract EXT1, Redo Thread 1, SCN 2.1665932 (8591600524), Redo Seq #326, Redo RBA 7945744. 2014-04-19 21:33:50 WARNING OGG-01027 Oracle GoldenGate Capture for Oracle, ext1.prm: Long Running Transaction: XID 29.22.494, Items 6614602, Extract EXT1, Redo Thread 1, SCN 2.1665932 (8591600524), Redo Seq #326, Redo RBA 7945744. 2014-04-19 21:34:00 WARNING OGG-01027 Oracle GoldenGate Capture for Oracle, ext1.prm: Long Running Transaction: XID 29.22.494, Items 7289144, Extract EXT1, Redo Thread 1, SCN 2.1665932 (8591600524), Redo Seq #326, Redo RBA 7945744. 2014-04-19 21:34:26 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000042. 2014-04-19 21:34:37 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000043. 2014-04-19 21:34:50 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000044. 2014-04-19 21:35:00 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000045. 2014-04-19 21:35:11 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000046. 2014-04-19 21:35:23 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000047. 2014-04-19 21:35:36 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000048. 2014-04-19 21:35:49 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000049. 2014-04-19 21:36:02 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000050. 2014-04-19 21:36:14 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000051. 2014-04-19 21:36:26 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000052. 2014-04-19 21:36:37 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000053. 2014-04-19 21:36:49 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000054. 2014-04-19 21:37:00 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000055. 2014-04-19 21:37:12 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000056. 2014-04-19 21:37:27 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000057. 2014-04-19 21:37:36 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000058. 2014-04-19 21:37:44 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000059. 2014-04-19 21:37:50 INFO OGG-01026 Oracle GoldenGate Capture for Oracle, ext1.prm: Rolling over remote file ./dirdat/ee000060.
下面是ogg应用端操作
--应用进程信息 GGSCI (enmotech) 49> info rpee REPLICAT RPEE Last Started 2014-04-19 21:53 Status ABENDED Checkpoint Lag 00:00:00 (updated 00:10:58 ago) Log Read Checkpoint File ./dirdat/ee000041 First Record RBA 1071 --这里进程停滞在SEQ 41 RBA 1071的地方 --使用logdump查看 ╭─oracle@enmotech /u01/ogg1 ╰─➤ ./logdump Oracle GoldenGate Log File Dump Utility for Oracle Version 11.2.1.0.1 OGGCORE_11.2.1.0.1_PLATFORMS_120423.0230 Copyright (C) 1995, 2012, Oracle and/or its affiliates. All rights reserved. Logdump 369 >ghdr on Logdump 370 >fileheader detail Logdump 371 >detail on Logdump 372 >detail data Logdump 373 >usertoken on Logdump 374 > Logdump 374 >open ./dirdat/ee000041 Current LogTrail is /u01/ogg1/dirdat/ee000041 Logdump 375 >n --trail文件头信息 2014/04/19 21:19:24.888.435 FileHeader Len 1004 RBA 0 Name: *FileHeader* 3000 0194 3000 0008 4747 0d0a 544c 0a0d 3100 0002 | 0...0...GG..TL..1... 0003 3200 0004 2000 0000 3300 0008 02f2 1d98 9233 | ..2... ...3........3 0d73 3400 0018 0016 7572 693a 656e 6d6f 7465 6368 | .s4.....uri:enmotech 3a3a 7530 313a 6f67 6731 3600 0013 0011 2e2f 6469 | ::u01:ogg16....../di 7264 6174 2f65 6530 3030 3034 3137 0000 0101 3800 | rdat/ee0000417....8. 0004 0000 0029 3900 0008 0000 0000 0000 042f 3aff | .....)9........../:. 0081 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... GroupID x30 '0' TrailInfo Info x00 Length 404 3000 0194 3000 0008 4747 0d0a 544c 0a0d 3100 0002 | 0...0...GG..TL..1... 0003 3200 0004 2000 0000 3300 0008 02f2 1d98 9233 | ..2... ...3........3 0d73 3400 0018 0016 7572 693a 656e 6d6f 7465 6368 | .s4.....uri:enmotech 3a3a 7530 313a 6f67 6731 3600 0013 0011 2e2f 6469 | ::u01:ogg16....../di 7264 6174 2f65 6530 3030 3034 3137 0000 0101 3800 | rdat/ee0000417....8. 0004 0000 0029 3900 0008 0000 0000 0000 042f 3aff | .....)9........../:. 0081 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 003b ff00 8100 0000 0000 | ...........;........ 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 3cff 0008 0000 0000 0000 0000 3dff 0008 | ....<...........=... 0000 0000 | .... TokenID x30 '0' Signature Info x00 Length 8 4747 0d0a 544c 0a0d | GG..TL.. TokenID x31 '1' Compatibility Info x00 Length 2 0003 | .. TokenID x32 '2' Charset Info x00 Length 4 2000 0000 | ... TokenID x33 '3' CreationTime Info x00 Length 8 02f2 1d98 9233 0d73 | .....3.s TokenID x34 '4' URI Info x00 Length 24 0016 7572 693a 656e 6d6f 7465 6368 3a3a 7530 313a | ..uri:enmotech::u01: 6f67 6731 | ogg1 TokenID x36 '6' Filename Info x00 Length 19 0011 2e2f 6469 7264 6174 2f65 6530 3030 3034 31 | .../dirdat/ee000041 TokenID x37 '7' MultiPart Info x00 Length 1 01 | . TokenID x38 '8' Seqno Info x00 Length 4 0000 0029 | ...) TokenID x39 '9' FileSize Info x00 Length 8 0000 0000 0000 042f | ......./ TokenID x3a ':' FirstCSN Info xff Length 129 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 00 | ......... TokenID x3b ';' LastCSN Info xff Length 129 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 00 | ......... TokenID x3c '<' FirstIOTime Info xff Length 8 0000 0000 0000 0000 | ........ TokenID x3d '=' LastIOTime Info xff Length 8 0000 0000 0000 0000 | ........ GroupID x31 '1' MachineInfo Info x00 Length 106 3100 006a 3000 0007 0005 4c69 6e75 7831 0000 0a00 | 1..j0.....Linux1.... 0865 6e6d 6f74 6563 6832 0000 1800 1632 2e36 2e33 | .enmotech2.....2.6.3 322d 3230 302e 3133 2e31 2e65 6c35 7565 6b33 0000 | 2-200.13.1.el5uek3.. 2500 2323 3120 534d 5020 5765 6420 4a75 6c20 3237 | %.##1 SMP Wed Jul 27 2032 313a 3032 3a33 3320 4544 5420 3230 3131 3400 | 21:02:33 EDT 20114. 0008 0006 7838 | ....x8 TokenID x30 '0' Sysname Info x00 Length 7 0005 4c69 6e75 78 | ..Linux TokenID x31 '1' Nodename Info x00 Length 10 0008 656e 6d6f 7465 6368 | ..enmotech TokenID x32 '2' Release Info x00 Length 24 0016 322e 362e 3332 2d32 3030 2e31 332e 312e 656c | ..2.6.32-200.13.1.el 3575 656b | 5uek TokenID x33 '3' Version Info x00 Length 37 0023 2331 2053 4d50 2057 6564 204a 756c 2032 3720 | .##1 SMP Wed Jul 27 3231 3a30 323a 3333 2045 4454 2032 3031 31 | 21:02:33 EDT 2011 TokenID x34 '4' Hardware Info x00 Length 8 0006 7838 365f 3634 | ..x86_64 GroupID x32 '2' DatabaseInfo Info x00 Length 351 3200 015f 3000 0002 0007 3100 0006 0004 4f52 434c | 2.._0.....1.....ORCL 3200 0006 0004 6f72 636c 3300 0004 0000 1389 3400 | 2.....orcl3.......4. 0002 000b 3500 0002 0002 3600 00e7 00e5 4f72 6163 | ....5.....6.....Orac 6c65 2044 6174 6162 6173 6520 3131 6720 456e 7465 | le Database 11g Ente 7270 7269 7365 2045 6469 7469 6f6e 2052 656c 6561 | rprise Edition Relea 7365 2031 312e 322e 302e 332e 3020 2d20 3634 6269 | se 11.2.0.3.0 - 64bi 7420 5072 6f64 7563 7469 6f6e 0a50 4c2f 5351 4c20 | t Production.PL/SQL 5265 6c65 6173 6520 3131 2e32 2e30 2e33 2e30 202d | Release 11.2.0.3.0 - 2050 726f 6475 6374 696f 6e0a 434f 5245 0931 312e | Production.CORE.11. 322e 302e 332e 3009 5072 6f64 7563 7469 6f6e 0a54 | 2.0.3.0.Production.T 4e53 2066 6f72 204c 696e 7578 3a20 5665 7273 696f | NS for Linux: Versio 6e20 3131 2e32 2e30 2e33 2e30 202d 2050 726f 6475 | n 11.2.0.3.0 - Produ 6374 696f 6e0a 4e4c 5352 544c 2056 6572 7369 6f6e | ction.NLSRTL Version 2031 312e 322e 302e 332e 3020 2d20 5072 6f64 7563 | 11.2.0.3.0 - Produc 7469 6f6e 0a37 0000 0440 0000 0038 0000 0c00 0a31 | tion.7...@...8.....1 312e 322e 302e 332e 3039 0000 0400 0000 013a 0000 | 1.2.0.3.09.......:.. 0200 003b 0000 0400 0000 013c 0000 1400 0000 1014 | ...;.......<........ 1414 1414 1414 1414 1414 14 | ........... TokenID x30 '0' Vendor Info x00 Length 2 0007 | .. TokenID x31 '1' Name Info x00 Length 6 0004 4f52 434c | ..ORCL TokenID x32 '2' Instance Info x00 Length 6 0004 6f72 636c | ..orcl TokenID x33 '3' Charset Info x00 Length 4 0000 1389 | .... TokenID x34 '4' MajorVersion Info x00 Length 2 000b | .. TokenID x35 '5' MinorVersion Info x00 Length 2 0002 | .. TokenID x36 '6' VerString Info x00 Length 231 00e5 4f72 6163 6c65 2044 6174 6162 6173 6520 3131 | ..Oracle Database 11 6720 456e 7465 7270 7269 7365 2045 6469 7469 6f6e | g Enterprise Edition 2052 656c 6561 7365 2031 312e 322e 302e 332e 3020 | Release 11.2.0.3.0 2d20 3634 6269 7420 5072 6f64 7563 7469 6f6e 0a50 | - 64bit Production.P 4c2f 5351 4c20 5265 6c65 6173 6520 3131 2e32 2e30 | L/SQL Release 11.2.0 2e33 2e30 202d 2050 726f 6475 6374 696f 6e0a 434f | .3.0 - Production.CO 5245 0931 312e 322e 302e 332e 3009 5072 6f64 7563 | RE.11.2.0.3.0.Produc 7469 6f6e 0a54 4e53 2066 6f72 204c 696e 7578 3a20 | tion.TNS for Linux: 5665 7273 696f 6e20 3131 2e32 2e30 2e33 2e30 202d | Version 11.2.0.3.0 - 2050 726f 6475 6374 696f 6e0a 4e4c 5352 544c 2056 | Production.NLSRTL V 6572 7369 6f6e 2031 312e 322e 302e 332e 3020 2d20 | ersion 11.2.0.3.0 - 5072 6f64 7563 7469 6f6e 0a | Production. TokenID x37 '7' ClientCharset Info x00 Length 4 4000 0000 | @... TokenID x38 '8' ClientVerString Info x00 Length 12 000a 3131 2e32 2e30 2e33 2e30 | ..11.2.0.3.0 TokenID x39 '9' ClientNCharset Info x00 Length 4 0000 0001 | .... TokenID x3a ':' DbLocale Info x00 Length 2 0000 | .. TokenID x3b ';' DbNCharset Info x00 Length 4 0000 0001 | .... TokenID x3c '<' DbObjNameMetadata Info x00 Length 20 0000 0010 1414 1414 1414 1414 1414 1414 1114 1414 | .................... GroupID x33 '3' ProducerInfo Info x00 Length 115 3300 0073 3000 0006 0004 4558 5431 3100 0002 0003 | 3..s0.....EXT11..... 3200 0002 000b 3300 0002 0002 3400 0002 0001 3500 | 2.....3.....4.....5. 0002 0000 3600 0002 0001 3700 0041 003f 5665 7273 | ....6.....7..A.?Vers 696f 6e20 3131 2e32 2e31 2e30 2e31 204f 4747 434f | ion 11.2.1.0.1 OGGCO 5245 5f31 312e 322e 312e 302e 315f 504c 4154 464f | RE_11.2.1.0.1_PLATFO 524d 535f 3132 3034 3233 2e30 3233 30 | RMS_120423.0230 TokenID x30 '0' Name Info x00 Length 6 0004 4558 5431 | ..EXT1 TokenID x31 '1' DataSource Info x00 Length 2 0003 | .. TokenID x32 '2' MajorVersion Info x00 Length 2 000b | .. TokenID x33 '3' MinorVersion Info x00 Length 2 0002 | .. TokenID x34 '4' MaintLevel Info x00 Length 2 0001 | .. TokenID x35 '5' BugFixLevel Info x00 Length 2 0000 | .. TokenID x36 '6' BuildNumber Info x00 Length 2 0001 | .. TokenID x37 '7' VerString Info x00 Length 65 003f 5665 7273 696f 6e20 3131 2e32 2e31 2e30 2e31 | .?Version 11.2.1.0.1 204f 4747 434f 5245 5f31 312e 322e 312e 302e 315f | OGGCORE_11.2.1.0.1_ 504c 4154 464f 524d 535f 3132 3034 3233 2e30 3233 | PLATFORMS_120423.023 305f 4642 4f | 0_FBO GroupID x34 '4' ContinunityInfo Info x00 Length 8 3400 0008 3000 0004 | 4...0... TokenID x30 '0' RecoveryMode Info x00 Length 4 0000 0001 | .... Logdump 376 >n ___________________________________________________________________ Hdr-Ind : E (x45) Partition : . (x00) UndoFlag : . (x00) BeforeAfter: A (x41) RecLength : 0 (x0000) IO Time : 2014/04/19 21:19:24.886.015 IOType : 151 (x97) OrigNode : 0 (x00) TransInd : . (x03) FormatType : R (x52) SyskeyLen : 0 (x00) Incomplete : . (x00) AuditRBA : 0 AuditPos : 0 Continued : N (x00) RecCount : 0 (x00) 2014/04/19 21:19:24.886.015 RestartOK Len 0 RBA 1012 Name: After Image: Partition 0 G s Logdump 400 >NEXTTRAIL LogTrail /u01/ogg1/dirdat/ee000041 closed Current LogTrail is /u01/ogg1/dirdat/ee000042 Logdump 402 >n ___________________________________________________________________ Hdr-Ind : E (x45) Partition : . (x00) UndoFlag : . (x00) BeforeAfter: A (x41) RecLength : 0 (x0000) IO Time : 2014/04/19 21:27:45.333.756 IOType : 151 (x97) OrigNode : 0 (x00) TransInd : . (x03) FormatType : R (x52) SyskeyLen : 0 (x00) Incomplete : . (x00) AuditRBA : 0 AuditPos : 0 Continued : N (x00) RecCount : 0 (x00) 2014/04/19 21:27:45.333.756 RestartOK Len 0 RBA 1012 Name: After Image: Partition 0 G s Logdump 403 >n ___________________________________________________________________ Hdr-Ind : E (x45) Partition : . (x04) UndoFlag : . (x00) BeforeAfter: B (x42) RecLength : 34 (x0022) IO Time : 2014/04/19 21:34:00.000.000 IOType : 15 (x0f) OrigNode : 255 (xff) TransInd : . (x00) FormatType : R (x52) SyskeyLen : 0 (x00) Incomplete : . (x00) AuditRBA : 326 AuditPos : 7945744 Continued : N (x00) RecCount : 1 (x01) 2014/04/19 21:34:00.000.000 FieldComp Len 34 RBA 1071 Name: OGG1.OGG_TEST Before Image: Partition 4 G b 0006 0015 0000 3230 3133 2d30 372d 3136 3a31 363a | ......2013-07-16:16: 3431 3a32 3800 0f00 0500 0000 0131 | 41:28........1 Column 6 (x0006), Len 21 (x0015) 0000 3230 3133 2d30 372d 3136 3a31 363a 3431 3a32 | ..2013-07-16:16:41:2 38 | 8 Column 15 (x000f), Len 5 (x0005) 0000 0001 31 | ....1 --这里可以看到 rba 1071 正好是 update操作的相关数据 --TransInd : . (x00) 为0 事务开始 --x00 - start of transaction --x01 - middle of transaction --x02 - end of transaction --x03 - only record in transaction Logdump 404 >n ___________________________________________________________________ Hdr-Ind : E (x45) Partition : . (x04) UndoFlag : . (x00) BeforeAfter: A (x41) RecLength : 34 (x0022) IO Time : 2014/04/19 21:34:00.000.000 IOType : 15 (x0f) OrigNode : 255 (xff) TransInd : . (x01) FormatType : R (x52) SyskeyLen : 0 (x00) Incomplete : . (x00) AuditRBA : 0 AuditPos : 7945744 Continued : N (x00) RecCount : 1 (x01) 2014/04/19 21:34:00.000.000 FieldComp Len 34 RBA 1224 Name: OGG1.OGG_TEST After Image: Partition 4 G m 0006 0015 0000 3230 3134 2d30 342d 3139 3a32 313a | ......2014-04-19:21: 3332 3a31 3500 0f00 0500 0000 0131 | 32:15........1 Column 6 (x0006), Len 21 (x0015) 0000 3230 3134 2d30 342d 3139 3a32 313a 3332 3a31 | ..2014-04-19:21:32:1 35 | 5 Column 15 (x000f), Len 5 (x0005) 0000 0001 31 | ....1 --通过SCANFORENDTRANS命令查找事务结束点 ,发现此trail没有,继续查看下一个trail文件,反复查找最后找到相应的rba Logdump 407 >SCANFORENDTRANS Scan reached EOF Logdump 408 >nexttrail LogTrail /u01/ogg1/dirdat/ee000042 closed Current LogTrail is /u01/ogg1/dirdat/ee000043 Logdump 409 >SCANFORENDTRANS Scan reached EOF Logdump 423 >nexttrail LogTrail /u01/ogg1/dirdat/ee000047 closed Current LogTrail is /u01/ogg1/dirdat/ee000048 Logdump 424 > Logdump 424 > --一直找到trail seq为61的文件找到了事务结束rba Logdump 462 >NEXTTRAIL LogTrail /u01/ogg1/dirdat/ee000060 closed Current LogTrail is /u01/ogg1/dirdat/ee000061 Logdump 463 >SCANFORENDTRANS End of Transaction found at RBA 0 2014/04/19 21:37:50.922.145 FileHeader Len 1164 RBA 0 Name: *FileHeader* 3000 0194 3000 0008 4747 0d0a 544c 0a0d 3100 0002 | 0...0...GG..TL..1... 0003 3200 0004 2000 0000 3300 0008 02f2 1d98 d41f | ..2... ...3......... c9a1 3400 0018 0016 7572 693a 656e 6d6f 7465 6368 | ..4.....uri:enmotech 3a3a 7530 313a 6f67 6731 3600 0013 0011 2e2f 6469 | ::u01:ogg16....../di 7264 6174 2f65 6530 3030 3036 3137 0000 0101 3800 | rdat/ee0000617....8. 0004 0000 003d 39ff 0008 0000 0000 0000 0000 3a00 | .....=9...........:. 0081 0a38 3539 3138 3236 3231 3400 0000 0000 0000 | ...8591826214....... GroupID x30 '0' TrailInfo Info x00 Length 404 3000 0194 3000 0008 4747 0d0a 544c 0a0d 3100 0002 | 0...0...GG..TL..1... 0003 3200 0004 2000 0000 3300 0008 02f2 1d98 d41f | ..2... ...3......... c9a1 3400 0018 0016 7572 693a 656e 6d6f 7465 6368 | ..4.....uri:enmotech 3a3a 7530 313a 6f67 6731 3600 0013 0011 2e2f 6469 | ::u01:ogg16....../di 7264 6174 2f65 6530 3030 3036 3137 0000 0101 3800 | rdat/ee0000617....8. 0004 0000 003d 39ff 0008 0000 0000 0000 0000 3a00 | .....=9...........:. 0081 0a38 3539 3138 3236 3231 3400 0000 0000 0000 | ...8591826214....... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 003b ff00 8100 0000 0000 | ...........;........ 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 3c00 0008 02f2 1d98 c65c 3200 3dff 0008 | ....<........\2.=... 0000 0000 | .... TokenID x30 '0' Signature Info x00 Length 8 4747 0d0a 544c 0a0d | GG..TL.. TokenID x31 '1' Compatibility Info x00 Length 2 0003 | .. TokenID x32 '2' Charset Info x00 Length 4 2000 0000 | ... TokenID x33 '3' CreationTime Info x00 Length 8 02f2 1d98 d41f c9a1 | ........ TokenID x34 '4' URI Info x00 Length 24 0016 7572 693a 656e 6d6f 7465 6368 3a3a 7530 313a | ..uri:enmotech::u01: 6f67 6731 | ogg1 TokenID x36 '6' Filename Info x00 Length 19 0011 2e2f 6469 7264 6174 2f65 6530 3030 3036 31 | .../dirdat/ee000061 TokenID x37 '7' MultiPart Info x00 Length 1 01 | . TokenID x38 '8' Seqno Info x00 Length 4 0000 003d | ...= TokenID x39 '9' FileSize Info xff Length 8 0000 0000 0000 0000 | ........ TokenID x3a ':' FirstCSN Info x00 Length 129 0a38 3539 3138 3236 3231 3400 0000 0000 0000 0000 | .8591826214......... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 00 | ......... TokenID x3b ';' LastCSN Info xff Length 129 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 00 | ......... TokenID x3c '<' FirstIOTime Info x00 Length 8 02f2 1d98 c65c 3200 | .....\2. TokenID x3d '=' LastIOTime Info xff Length 8 0000 0000 0000 0000 | ........ GroupID x31 '1' MachineInfo Info x00 Length 106 3100 006a 3000 0007 0005 4c69 6e75 7831 0000 0a00 | 1..j0.....Linux1.... 0865 6e6d 6f74 6563 6832 0000 1800 1632 2e36 2e33 | .enmotech2.....2.6.3 322d 3230 302e 3133 2e31 2e65 6c35 7565 6b33 0000 | 2-200.13.1.el5uek3.. 2500 2323 3120 534d 5020 5765 6420 4a75 6c20 3237 | %.##1 SMP Wed Jul 27 2032 313a 3032 3a33 3320 4544 5420 3230 3131 3400 | 21:02:33 EDT 20114. 0008 0006 7838 | ....x8 TokenID x30 '0' Sysname Info x00 Length 7 0005 4c69 6e75 78 | ..Linux TokenID x31 '1' Nodename Info x00 Length 10 0008 656e 6d6f 7465 6368 | ..enmotech TokenID x32 '2' Release Info x00 Length 24 0016 322e 362e 3332 2d32 3030 2e31 332e 312e 656c | ..2.6.32-200.13.1.el 3575 656b | 5uek TokenID x33 '3' Version Info x00 Length 37 0023 2331 2053 4d50 2057 6564 204a 756c 2032 3720 | .##1 SMP Wed Jul 27 3231 3a30 323a 3333 2045 4454 2032 3031 31 | 21:02:33 EDT 2011 TokenID x34 '4' Hardware Info x00 Length 8 0006 7838 365f 3634 | ..x86_64 GroupID x32 '2' DatabaseInfo Info x00 Length 351 3200 015f 3000 0002 0007 3100 0006 0004 4f52 434c | 2.._0.....1.....ORCL 3200 0006 0004 6f72 636c 3300 0004 0000 1389 3400 | 2.....orcl3.......4. 0002 000b 3500 0002 0002 3600 00e7 00e5 4f72 6163 | ....5.....6.....Orac 6c65 2044 6174 6162 6173 6520 3131 6720 456e 7465 | le Database 11g Ente 7270 7269 7365 2045 6469 7469 6f6e 2052 656c 6561 | rprise Edition Relea 7365 2031 312e 322e 302e 332e 3020 2d20 3634 6269 | se 11.2.0.3.0 - 64bi 7420 5072 6f64 7563 7469 6f6e 0a50 4c2f 5351 4c20 | t Production.PL/SQL 5265 6c65 6173 6520 3131 2e32 2e30 2e33 2e30 202d | Release 11.2.0.3.0 - 2050 726f 6475 6374 696f 6e0a 434f 5245 0931 312e | Production.CORE.11. 322e 302e 332e 3009 5072 6f64 7563 7469 6f6e 0a54 | 2.0.3.0.Production.T 4e53 2066 6f72 204c 696e 7578 3a20 5665 7273 696f | NS for Linux: Versio 6e20 3131 2e32 2e30 2e33 2e30 202d 2050 726f 6475 | n 11.2.0.3.0 - Produ 6374 696f 6e0a 4e4c 5352 544c 2056 6572 7369 6f6e | ction.NLSRTL Version 2031 312e 322e 302e 332e 3020 2d20 5072 6f64 7563 | 11.2.0.3.0 - Produc 7469 6f6e 0a37 0000 0440 0000 0038 0000 0c00 0a31 | tion.7...@...8.....1 312e 322e 302e 332e 3039 0000 0400 0000 013a 0000 | 1.2.0.3.09.......:.. 0200 003b 0000 0400 0000 013c 0000 1400 0000 1014 | ...;.......<........ 1414 1414 1414 1414 1414 14 | ........... TokenID x30 '0' Vendor Info x00 Length 2 0007 | .. TokenID x31 '1' Name Info x00 Length 6 0004 4f52 434c | ..ORCL TokenID x32 '2' Instance Info x00 Length 6 0004 6f72 636c | ..orcl TokenID x33 '3' Charset Info x00 Length 4 0000 1389 | .... TokenID x34 '4' MajorVersion Info x00 Length 2 000b | .. TokenID x35 '5' MinorVersion Info x00 Length 2 0002 | .. TokenID x36 '6' VerString Info x00 Length 231 00e5 4f72 6163 6c65 2044 6174 6162 6173 6520 3131 | ..Oracle Database 11 6720 456e 7465 7270 7269 7365 2045 6469 7469 6f6e | g Enterprise Edition 2052 656c 6561 7365 2031 312e 322e 302e 332e 3020 | Release 11.2.0.3.0 2d20 3634 6269 7420 5072 6f64 7563 7469 6f6e 0a50 | - 64bit Production.P 4c2f 5351 4c20 5265 6c65 6173 6520 3131 2e32 2e30 | L/SQL Release 11.2.0 2e33 2e30 202d 2050 726f 6475 6374 696f 6e0a 434f | .3.0 - Production.CO 5245 0931 312e 322e 302e 332e 3009 5072 6f64 7563 | RE.11.2.0.3.0.Produc 7469 6f6e 0a54 4e53 2066 6f72 204c 696e 7578 3a20 | tion.TNS for Linux: 5665 7273 696f 6e20 3131 2e32 2e30 2e33 2e30 202d | Version 11.2.0.3.0 - 2050 726f 6475 6374 696f 6e0a 4e4c 5352 544c 2056 | Production.NLSRTL V 6572 7369 6f6e 2031 312e 322e 302e 332e 3020 2d20 | ersion 11.2.0.3.0 - 5072 6f64 7563 7469 6f6e 0a | Production. TokenID x37 '7' ClientCharset Info x00 Length 4 4000 0000 | @... TokenID x38 '8' ClientVerString Info x00 Length 12 000a 3131 2e32 2e30 2e33 2e30 | ..11.2.0.3.0 TokenID x39 '9' ClientNCharset Info x00 Length 4 0000 0001 | .... TokenID x3a ':' DbLocale Info x00 Length 2 0000 | .. TokenID x3b ';' DbNCharset Info x00 Length 4 0000 0001 | .... TokenID x3c '<' DbObjNameMetadata Info x00 Length 20 0000 0010 1414 1414 1414 1414 1414 1414 1114 1414 | .................... GroupID x33 '3' ProducerInfo Info x00 Length 115 3300 0073 3000 0006 0004 4558 5431 3100 0002 0003 | 3..s0.....EXT11..... 3200 0002 000b 3300 0002 0002 3400 0002 0001 3500 | 2.....3.....4.....5. 0002 0000 3600 0002 0001 3700 0041 003f 5665 7273 | ....6.....7..A.?Vers 696f 6e20 3131 2e32 2e31 2e30 2e31 204f 4747 434f | ion 11.2.1.0.1 OGGCO 5245 5f31 312e 322e 312e 302e 315f 504c 4154 464f | RE_11.2.1.0.1_PLATFO 524d 535f 3132 3034 3233 2e30 3233 30 | RMS_120423.0230 TokenID x30 '0' Name Info x00 Length 6 0004 4558 5431 | ..EXT1 TokenID x31 '1' DataSource Info x00 Length 2 0003 | .. TokenID x32 '2' MajorVersion Info x00 Length 2 000b | .. TokenID x33 '3' MinorVersion Info x00 Length 2 0002 | .. TokenID x34 '4' MaintLevel Info x00 Length 2 0001 | .. TokenID x35 '5' BugFixLevel Info x00 Length 2 0000 | .. TokenID x36 '6' BuildNumber Info x00 Length 2 0001 | .. TokenID x37 '7' VerString Info x00 Length 65 003f 5665 7273 696f 6e20 3131 2e32 2e31 2e30 2e31 | .?Version 11.2.1.0.1 204f 4747 434f 5245 5f31 312e 322e 312e 302e 315f | OGGCORE_11.2.1.0.1_ 504c 4154 464f 524d 535f 3132 3034 3233 2e30 3233 | PLATFORMS_120423.023 305f 4642 4f | 0_FBO GroupID x34 '4' ContinunityInfo Info x00 Length 168 3400 00a8 3000 0004 0000 0001 3300 0081 0a38 3539 | 4...0.......3....859 3138 3236 3231 3400 0000 0000 0000 0000 0000 0000 | 1826214............. 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0034 0000 0b00 0932 392e 3232 2e34 3934 | .....4.....29.22.494 3500 0008 02f2 1d98 | 5....... TokenID x30 '0' RecoveryMode Info x00 Length 4 0000 0001 | .... TokenID x33 '3' LastCSN Info x00 Length 129 0a38 3539 3138 3236 3231 3400 0000 0000 0000 0000 | .8591826214......... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 | .................... 0000 0000 0000 0000 00 | ......... TokenID x34 '4' LastXID Info x00 Length 11 0009 3239 2e32 322e 3439 34 | ..29.22.494 --这里显示了此文件的最后一个xid号 29.22.494 和上面相符 TokenID x35 '5' LastCSNTS Info x00 Length 8 02f2 1d98 c65c 3200 | .....\2. Logdump 464 >SCANFORENDTRANS End of Transaction found at RBA 25163672 --找到rba为25163672 ___________________________________________________________________ Hdr-Ind : E (x45) Partition : . (x04) UndoFlag : . (x00) BeforeAfter: A (x41) RecLength : 40 (x0028) IO Time : 2014/04/19 21:34:00.000.000 IOType : 15 (x0f) OrigNode : 255 (xff) TransInd : . (x02) FormatType : R (x52) SyskeyLen : 0 (x00) Incomplete : . (x00) AuditRBA : 0 AuditPos : 3681604 Continued : N (x00) RecCount : 1 (x01) --TransInd : . (x02) 事务结束 2014/04/19 21:34:00.000.000 FieldComp Len 40 RBA 25163672 Name: OGG1.OGG_TEST After Image: Partition 4 G e 0006 0015 0000 3230 3134 2d30 342d 3139 3a32 313a | ......2014-04-19:21: 3332 3a31 3500 0f00 0b00 0000 0737 3330 3036 3038 | 32:15........7300608 Column 6 (x0006), Len 21 (x0015) 0000 3230 3134 2d30 342d 3139 3a32 313a 3332 3a31 | ..2014-04-19:21:32:1 35 | 5 Column 15 (x000f), Len 11 (x000b) 0000 0007 3733 3030 3630 38 | ....7300608 Logdump 465 > --查看下一个rba Logdump 466 >n ___________________________________________________________________ Hdr-Ind : E (x45) Partition : . (x04) UndoFlag : . (x00) BeforeAfter: A (x41) RecLength : 169 (x00a9) IO Time : 2014/04/19 22:07:12.000.000 IOType : 5 (x05) OrigNode : 255 (xff) TransInd : . (x03) FormatType : R (x52) SyskeyLen : 0 (x00) Incomplete : . (x00) AuditRBA : 382 AuditPos : 8109072 Continued : N (x00) RecCount : 1 (x01) 2014/04/19 22:07:12.000.000 Insert Len 169 RBA 25163804 Name: OGG1.OGG_TEST After Image: Partition 4 G s 0000 0004 ffff 0000 0001 0004 ffff 0000 0002 0004 | .................... ffff 0000 0003 0004 ffff 0000 0004 0004 ffff 0000 | .................... 0005 0004 ffff 0000 0006 0015 ffff 3139 3030 2d30 | ..............1900-0 312d 3031 3a30 303a 3030 3a30 3000 0700 15ff ff31 | 1-01:00:00:00......1 3930 302d 3031 2d30 313a 3030 3a30 303a 3030 0008 | 900-01-01:00:00:00.. 0004 ffff 0000 0009 0004 ffff 0000 000a 0004 ffff | .................... 0000 000b 0004 ffff 0000 000c 0004 ffff 0000 000d | .................... Column 0 (x0000), Len 4 (x0004) ffff 0000 | .... Column 1 (x0001), Len 4 (x0004) ffff 0000 | .... Column 2 (x0002), Len 4 (x0004) ffff 0000 | .... Column 3 (x0003), Len 4 (x0004) ffff 0000 | .... Column 4 (x0004), Len 4 (x0004) ffff 0000 | .... Column 5 (x0005), Len 4 (x0004) ffff 0000 | .... Column 6 (x0006), Len 21 (x0015) ffff 3139 3030 2d30 312d 3031 3a30 303a 3030 3a30 | ..1900-01-01:00:00:0 30 | 0 Column 7 (x0007), Len 21 (x0015) ffff 3139 3030 2d30 312d 3031 3a30 303a 3030 3a30 | ..1900-01-01:00:00:0 30 | 0 Column 8 (x0008), Len 4 (x0004) ffff 0000 | .... Column 9 (x0009), Len 4 (x0004) ffff 0000 | .... Column 10 (x000a), Len 4 (x0004) ffff 0000 | .... Column 11 (x000b), Len 4 (x0004) ffff 0000 | .... Column 12 (x000c), Len 4 (x0004) ffff 0000 | .... Column 13 (x000d), Len 4 (x0004) ffff 0000 | .... Column 14 (x000e), Len 4 (x0004) ffff 0000 | .... Column 15 (x000f), Len 11 (x000b) 0000 0007 3733 3030 3630 39 | ....7300609 --次操作为一次insert操作 --现在我们找了下一个事务的开始地址 seq 61 rba 25163804 --修改rpee检查点信息 GGSCI (enmotech) 50> alter rpee ,EXTSEQNO 61 ,extrba 25163804 REPLICAT altered. GGSCI (enmotech) 51> start rpee Sending START request to MANAGER ... REPLICAT RPEE starting GGSCI (enmotech) 52> info rpee REPLICAT RPEE Last Started 2014-04-19 22:08 Status RUNNING Checkpoint Lag 00:00:00 (updated 00:00:08 ago) Log Read Checkpoint File ./dirdat/ee000061 2014-04-19 22:07:12.000000 RBA 25164092 GGSCI (enmotech) 53> stats rpee Sending STATS request to REPLICAT RPEE ... Start of Statistics at 2014-04-19 22:08:26. Replicating from OGG1.OGG_TEST to OGG2.OGG_TEST: *** Total statistics since 2014-04-19 22:08:07 *** Total inserts 1.00 Total updates 0.00 Total deletes 0.00 Total discards 0.00 Total operations 1.00 *** Daily statistics since 2014-04-19 22:08:07 *** Total inserts 1.00 Total updates 0.00 Total deletes 0.00 Total discards 0.00 Total operations 1.00 *** Hourly statistics since 2014-04-19 22:08:07 *** Total inserts 1.00 Total updates 0.00 Total deletes 0.00 Total discards 0.00 Total operations 1.00 *** Latest statistics since 2014-04-19 22:08:07 *** Total inserts 1.00 Total updates 0.00 Total deletes 0.00 Total discards 0.00 Total operations 1.00 End of Statistics. GGSCI (enmotech) 54> --ogg正常运行,此事务跳过
如非注明,本站文章皆为原创。
转载请注明:转载自: GoldenGate_Replicat_Skip_Long_Transaction