ITPub博客

首页 > Linux操作系统 > Linux操作系统 > goldengate oracle to mysql配置

goldengate oracle to mysql配置

原创 Linux操作系统 作者:lijiebin 时间:2010-12-07 13:36:21 0 删除 编辑


extract的mgr参数:
PORT 7809
DYNAMICPORTLIST 7840-7850

添加提取进程:
add extract exttmy,sourceistable 

exttmy参数:

extract exttmy
userid gg,password gg
rmthost 192.168.6.12, mgrport 7809
rmttask replicat, group reptmy
table seashell.testgg;

配置defgen

1  edit params defgen
DEFSFILE /home/oracle/ggoracle/dirdef/seashell.def
userid gg,password gg
table seashell.testgg;

2
defgen paramfile dirprm/defgen.prm

[oracle@apex ggoracle]$ defgen paramfile dirprm/defgen.prm

Definitions generated for 1 tables in /home/oracle/ggoracle/dirdef/seashell.def

3
scp -r /home/oracle/ggoracle/dirdef/seashell.def 192.168.6.12:/root/ggmysql/dirdef


replicat的mgr参数:
PORT 7809
DYNAMICPORTLIST 7440-7450

MYSQL端添加复制进程:
add replicat reptmy,specialrun --表示一次性加载,

参数:
replicat reptmy
sourcedefs /root/ggmysql/dirdef/seashell.def
SOURCEDB SEASHELL, USERID root, PASSWORD root
MAP SEASHELL.TESTGG, TARGET SEASHELL.TESTGG;

要开始加载,在源端执行:
start exttmy
********************************************************************
===================================================================
dml 同步

新增抽取进程
add extract extmysql,tranlog,begin now
ADD EXTTRAIL ./dirdat/dd, EXTRACT extmysql, MEGABYTES 5
edit params extmysql

EXTRACT extmysql
USERID gg, PASSWORD gg
EXTTRAIL ./dirdat/dd
--DDL
TABLE SEASHELL.TESTGG;
==========================================
添加pump

edit params pumpmy
EXTRACT pumpmy
PASSTHRU
RMTHOST 192.168.6.12, MGRPORT 7809
RMTTRAIL ./dirdat/dd
TABLE SEASHELL.TESTGG;

ADD EXTRACT pumpmy, EXTTRAILSOURCE ./dirdat/dd
ADD RMTTRAIL ./dirdat/dd, EXTRACT pumpmy,MEGABYTES 5


START EXTRACT extmysql
START EXTRACT pumpmy

**************************************************************
目标库
chkpt_ora_create.sql

dblogin userid root,password root
ADD REPLICAT repmy,CHECKPOINTTABLE SEASHELL.GGS_CHECKPOINT,EXTTRAIL ./dirdat/dd


edit params repmy
REPLICAT repmy
sourcedefs /root/ggmysql/dirdef/seashell.def
SOURCEDB SEASHELL, USERID root, PASSWORD root
DISCARDFILE ./dirrpt/billrep.dsc,PURGE
MAP SEASHELL.TESTGG, TARGET SEASHELL.TESTGG;

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/8135069/viewspace-681067/,如需转载,请注明出处,否则将追究法律责任。

下一篇: shared pool 结构
请登录后发表评论 登录
全部评论

注册时间:2008-01-10

  • 博文量
    145
  • 访问量
    152111