本文主要是介绍Oracle GoldenGate Trail file encryption,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
GoldenGate加密trail文件非常简单,只需要在extract参数中加上encrypttrail参数。extract进程就会对加入此参数后所生产的trail文件进行加密,如果目标端的replicat参数没有加上对应的decrypttrail参数解密trail文件后再入库,replicat进程就会abend
源端extract参数
GGSCI (gg01) 5> VIEW params eorajjEXTRACT EORAJJ
USERID system, PASSWORD oracle
RMTHOST gg02, MGRPORT 7809
--加密参数
ENCRYPTTRAIL
RMTTRAIL /u01/app/oracle/goldengate/dirdat/jjDDL INCLUDE ALL
DDLOPTIONS ADDTRANDATA,REPORT
TRANLOGOPTIONS CONVERTUCS2CLOBSTABLE scott.stu;
SEQUENCE scott.*;
源端插入数据测试
SCOTT@gg01:~>INSERT INTO stu 2 VALUES 3 (5,'TEST','TEST@126.com','138xxxxxxxx','TRAIL');1 ROW created.SCOTT@gg01:~>commit;Commit complete.
查看目标端的replicat进程状态
GGSCI (gg02) 14> info ALLProgram STATUS GROUP Lag TIME Since ChkptMANAGER RUNNING
REPLICAT ABENDED RORAJJ 00:00:00 00:00:09
在目标端replicat加入解密参数
GGSCI (gg02) 3> VIEW params rorajjREPLICAT RORAJJ
USERID system, PASSWORD oracle
HANDLECOLLISIONS
ASSUMETARGETDEFS
--解密参数
DECRYPTTRAIL
DISCARDFILE /u01/app/oracle/goldengate/dirrpt/RORAJJ.DSC, PURGEDDL INCLUDE MAPPED
DDLOPTIONS REPORTCOLMATCH NAMES STUDENT_ID = STU_ID
COLMATCH NAMES STUDENT_NAME = STU_NAME
COLMATCH NAMES STUDENT_EMAIL = STU_EMAIL
COLMATCH PREFIX STU_MAP scott.stu, TARGET scott.student, COLMAP (USEDEFAULTS);COLMATCH RESET
这篇关于Oracle GoldenGate Trail file encryption的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!