goldengate 应用进程自进行拆分时最好按照业务进行拆分,否则有可能造成应用读取数据是业务错乱,现将多个应用进程合并为一个应用进程,以下为步骤,仅供参考:
合并replicate应用进程:
1.原进程:
GGSCI (data) 142> info all
Program Status Group Lag at Chkpt Time Since Chkpt
MANAGER RUNNING
REPLICAT RUNNING REP1 00:00:00 00:00:03
REPLICAT RUNNING REP2 00:00:00 00:00:02
REPLICAT RUNNING REP3 00:00:00 00:00:02
REPLICAT RUNNING REP4 00:00:00 00:00:01
2.现需要将REP进程合并为一个进程,添加一个新的应用进程:
add replicat rep,exttrail ./dirdat/aa, checkpointtable goldengate.checkpoint
把需要合并的表全部添加到新的进程中:
edit params rep
3.停止pump进程:
stop p_data
4.观察应用进程的seqno和rba使之到达一致:
GGSCI (data) 156> info rep1
REPLICAT R_WMSJQ Last Started 2018-11-21 11:18 Status RUNNING
Checkpoint Lag 00:00:00 (updated 00:00:08 ago)
Process ID 45169
Log Read Checkpoint File ./dirdat/bb000012890
2018-11-21 11:32:30.999468 RBA 340450388
5.停掉应用进程:
stop rep1
stop rep2
stop rep3
stop rep4
6.修改新的应用进程的seqno和rba:
alter rep, extseqno 12890, extrba 340450388
start rep
7.删掉之前的分进程:
dblogin userid goldengate,password goldengate
stop rep1
delete replicat rep1
免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。