iis服务器助手广告广告
返回顶部
首页 > 资讯 > 数据库 >完整的goldengate抽取、pump和replicate进程配置
  • 543
分享到

完整的goldengate抽取、pump和replicate进程配置

2024-04-02 19:04:59 543人浏览 薄情痞子
摘要

抽取进程:extract ext_codeSETENV (NLS_LANG="AMERICAN_AMERICA.AL32UTF8")SETENV (oracle_HOME = "

抽取进程:
extract ext_code
SETENV (NLS_LANG="AMERICAN_AMERICA.AL32UTF8")
SETENV (oracle_HOME = "/app/oracle/product/10.2.0/db")
SETENV (ORACLE_SID = chunqiu)
userid Goldengate@chunqiu,passWord AACAAAAAAAAAAAKAPATACEHBIGQGCFZCCDIGAEMCQFFBZHVC, ENCRYPTKEY DEFAULT
exttrail ./dirdat/de
--tranlogoptions excludeuser goldengate
dynamicresolution
WARNLONGTRANS 3h, CHECKINTERVAL 30m
gettruncates
tranlogoptions altarcHivelogdest +DG1/gbbarcode/archivelog/
TRANLOGOPTIONS ASMUSER SYS@ASM, ASMPASSWORD oracle
table chunqiu.plm_acc_serial;
table chunqiu.plm_acc_serial_tsc;

ADD EXTRACT ext_code,tranlog,BEGIN now
ADD exttrail ./dirdat/de,EXTRACT ext_code,megabytes 200

pump进程:
extract pum_code
SETENV (NLS_LANG="AMERICAN_AMERICA.AL32UTF8")
SETENV (ORACLE_HOME = "/app/oracle/product/10.2.0/db")
SETENV (ORACLE_SID = chunqiu)
userid goldengate@chunqiu,password AACAAAAAAAAAAAKAPATACEHBIGQGCFZCCDIGAEMCQFFBZHVC, ENCR
YPTKEY DEFAULT
rmthost 192.168.50.68, mgrport 7801
rmttrail ./dirdat/cc
PASSTHRU
gettruncates
table chunqiu.plm_acc_serial;
table chunqiu.plm_acc_serial_tsc;

ADD EXTRACT pum_code,exttrailsource ./dirdat/de
ADD rmttrail ./dirdat/cc,EXTRACT pum_code,megabytes 200

应用进程:
数据库修改参数,11g之前不需要设置enable_goldengate_replication参数:
alter system set enable_goldengate_replication=true scope=both;

数据库添加goldengate用户:
create tablespace OGG_TBS datafile size 10G autoextend on next 100m maxsize unlimited;
create user goldengate default tablespace OGG_TBS identified by goldengate;
grant dba to goldengate ;

添加checkpoint表:
dblogin userid goldengate,password goldengate
add checkpointtable goldengate.checkpoint
EDIT PARAMS ./GLOBALS
CHECKPOINTTABLE goldengate.checkpoint

replicat rep_code
SETENV (NLS_LANG="AMERICAN_AMERICA.AL32UTF8")
userid goldengate,password goldengate
assumetargetdefs
reperror default,discard
discardfile /goldengate/rep_code.log,append,megabytes 1000
gettruncates
map chunqiu.PLM_ACC_SERIAL, target idc.PLM_ACC_SERIAL;
map chunqiu.PLM_ACC_SERIAL_TSC, target idc.PLM_ACC_SERIAL_TSC;

add replicat rep_code,exttrail ./dirdat/cc, checkpointtable goldengate.checkpoint
start rep_code,aftercsn 112892036392

删掉replicat进程:
注意:一定要登录到dblogin到目标数据库,否则提示要删除checkpoint table
dblogin userid goldengate,password goldengate
stop rep_code
delete replicat rep_code

您可能感兴趣的文档:

--结束END--

本文标题: 完整的goldengate抽取、pump和replicate进程配置

本文链接: https://www.lsjlt.com/news/39868.html(转载时请注明来源链接)

有问题或投稿请发送至: 邮箱/279061341@qq.com    QQ/279061341

本篇文章演示代码以及资料文档资料下载

下载Word文档到电脑,方便收藏和打印~

下载Word文档
猜你喜欢
软考高级职称资格查询
编程网,编程工程师的家园,是目前国内优秀的开源技术社区之一,形成了由开源软件库、代码分享、资讯、协作翻译、讨论区和博客等几大频道内容,为IT开发者提供了一个发现、使用、并交流开源技术的平台。
  • 官方手机版

  • 微信公众号

  • 商务合作