GoldenGate PUMP复制

       配置管理进程和抽取进程
./ggsci
 >dblogin userid ogg,password ufsoft
 >edit params mgr            --编辑管理进程
        PORT 7809
 >start mgr
       >edit params GLOBALS
        GGSCHEMA ogg
       >edit extract eini_1
          EXTRACT EINI_1
          dynamicresolution
          SETENV (NLS_LANG=AMERICAN_AMERICA.ZHS16GBK)
          USERID ogg PASSWORD ufsoft
          RMTHOST 192.168.0.4,MGRPORT 7809
          TRANLOGOPTIONS EXCLUDEUSER ogg
          exttrail /oracle/goldengate/dirdat/la
          DDL INCLUDE ALL
          table scott.*;
       >add extract eini_1,tranlog,begin now
                     >add extract eini_1,tranlog,begin now
                     >add exttrail /oracle/goldengate/dirdat/la,extract eini_1
                     >edit params pump_so //配置 pump进程
                         extract pump_so
                         dynamicresolution
                         rmthost 192.168.0.4,mgrport 7809,compress
                         rmttrail /oracle/goldengate/dirdat/ma
                         table scott.* //如果需要对多个用户下的表进行通步的话,建议多建立几个抽取进程,以免其中一个进程出现意外停止而导致所有抽取进程都停止,减少数据的丢失。
                     > add extract pump_so,exttrailsource /oracle/goldengate/dirdat/la
                     > add rmttrail /oracle/goldengate/dirdat/ma,extract pump_so
2)         配置复制进程
 >add checkpointtable ogg.checkpoint
 >add replicat rini_1,exttrail /oracle/goldengate/dirdat/ra,begin now,checkpointtable ogg.checkpoint
 >edit params rini_1
  REPLICAT RINI_1
  SETENV (NLS_LANG=AMERICAN_AMERICA.ZHS16GBK)
  ASSUMETARGETDEFS
  USERID ogg PASSWORD ufsoft
  DISCARDFILE /oracle/goldengate/dirrpt/RINIaa.dsc,PURGE
  DDL INCLUDE ALL
  DDLERROR DEFAULT IGNORE RETRYOP MAXRETRIES 3 RETRYDELAY 5
  DDLERROR DEFAULT DISCARD
  DDLERROR DEFAULT IGNORE RETRYOP
  MAP scott.* , TARGET scott.*;
开启各进程。
1)         配置管理进程和复制进程
               目标端只需要配置两个进程即可:管理进程和复制进程
                                     ./ggsci
                >dblogin userid ogg,password ufsoft
                >edit params mgr
                    PORT 7809
                  PURGEOLDEXTRACTS /dirdat,USECHECKPOINTS
                >start mgr
                >edit params GLOBALS   //全局配置,非必须
                    GGSCHEMA ogg
                >add checkpointtable ogg.checkpoint
                >add replicat rini_1,exttrail /oracle/goldengate/dirdat/ma,begin now,checkpointtable ogg.checkpoint
                >edit params rini_1
                 REPLICAT RINI_1
                 SETENV (NLS_LANG=AMERICAN_AMERICA.ZHS16GBK)
                 ASSUMETARGETDEFS
                 USERID ogg PASSWORD ufsoft
                 DISCARDFILE /oracle/goldengate/dirrpt/RINIaa.dsc,PURGE
                 DDL INCLUDE ALL
                 DDLERROR DEFAULT IGNORE RETRYOP MAXRETRIES 3 RETRYDELAY 5
                 DDLERROR DEFAULT DISCARD
                 DDLERROR DEFAULT IGNORE RETRYOP
                 MAP scott.* , TARGET scott.*;
2)         配置抽取进程
>edit params eini_1
  EXTRACT EINI_1
  dynamicresolution
  SETENV (NLS_LANG=AMERICAN_AMERICA.ZHS16GBK)
  USERID ogg PASSWORD ufsoft
  RMTHOST 192.168.0.3,MGRPORT 7809
  TRANLOGOPTIONS EXCLUDEUSER ogg
  exttrail /oracle/goldengate/dirdat/na
  DDL INCLUDE ALL
  table scott.*;
       >add extract eini_1,tranlog,begin now
 >add exttrail /oracle/goldengate/dirdat/na,extract eini_1
 >edit params pump_so
  extract pump_so
  dynamicresolution
  USERID ogg PASSWORD ufsoft
  rmthost 192.168.0.3,mgrport 7809,compress
  rmttrail /oracle/goldengate/dirdat/ra
  table scott.*;
 > add extract pump_so,exttrailsource /oracle/goldengate/dirdat/na
 > add rmttrail /oracle/goldengate/dirdat/ra,extract pump_so

开启所有进程。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值