GoldenGate全部删除Trail 文件恢复

简介:

    今天在清理GoldenGate的Trail文件时一不小心全部删除了,导致GoldenGate在源端的EXTRACT进程挂起不能启动.


1.删除源端数据库的EXTRACT进程:
GGSCI (crm_master) 4> dblogin userid ogg,password OC8rGBIjkBG
Successfully logged into database.
GGSCI (crm_master) 5> delete extract EXTND
Deleted EXTRACT EXTND.
GGSCI (crm_master) 6> info all
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
MANAGER    RUNNING                              
EXTRACT     RUNNING     DPEND       00:00:00      00:00:06    
GGSCI (crm_master) 7> add exttrail ./gglog/nd,extract EXTND,megabytes 1000
EXTTRAIL added.
GGSCI (crm_master) 8> ADD EXTTRAIL /oradata/gglog/nd, EXTRACT EXTND
EXTTRAIL added.
GGSCI (crm_master) 9> info all
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
MANAGER   RUNNING                                     
EXTRACT     RUNNING     DPEND       00:00:00      00:00:04    
EXTRACT     STOPPED     EXTND       00:00:00      00:07:42    
GGSCI (crm_master) 10> start extnd
Sending START request to MANAGER ...
EXTRACT EXTND starting
GGSCI (crm_master) 11> info all
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
MANAGER    RUNNING               
EXTRACT     RUNNING     DPEND       00:00:00      00:00:09    
EXTRACT     RUNNING     EXTND       00:07:46      00:00:01    
GGSCI (crm_master) 12>


2.进看源端数据库的Trail文件号

[oracle@node1 ogg]$ ll ../gglog/
total 724
-rw-rw-rw- 1 oracle oinstall 737414 Jul 27 14:34 nd000000
[oracle@node1 ogg]$ 


3.在目标端数据库指定Trail号

GGSCI (crm_slave) 5> alter REPLICAT repl extseqno 000, extrba 0        
REPLICAT altered.
GGSCI (crm_slave) 6> start repl
Sending START request to MANAGER ...
REPLICAT REPL starting
GGSCI (crm_slave) 7> info all
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
MANAGER  RUNNING                                 
REPLICAT    RUNNING     REPL        00:00:00      00:00:00    
GGSCI (crm_slave) 8>










本文转自 z597011036 51CTO博客,原文链接:http://blog.51cto.com/tongcheng/1951415,如需转载请自行联系原作者
目录
相关文章
|
测试技术 数据库
[20180202]备库数据文件offline.txt
[20180202]备库数据文件offline.txt --//今天测试,不小心导致日志无法应用.我想把主库文件拷贝过去,做了备库数据文件offline. --//恢复遇到问题,做一个记录.
1264 0
|
监控 Oracle 关系型数据库
|
Oracle 关系型数据库 数据库
[20161012]数据文件offline马上执行recover
[20161012]数据文件offline马上执行recover.txt --前几天看的1篇文章,提到数据文件offline,应该养成随手执行recover习惯.保证下一次online时,不需要恢复。
826 0