【gg notes】config gg for windows x86 32bit ,two node

Let's improve the single node configuration sample to two nodes of win x86 32-bit

In fact, we are still in the same machine, but we have two gg manager, one for source and the other for target.

The paths on my windows XP system are:

Source:

D:\ggs

Target:

D:\ggt

 

1, Prepare the install environment

OS: windows XP(x86-32-bit)

DB: Oracle11R2

GG: ggs_Windows_x86_ora11g_32bit

Network: single node test

 

2, Download GG for windows x86-32-bit-edition, just for test

This is the web link:

http://www.oracle.com/technetwork/middleware/goldengate/downloads/index.html

 

3, Extract file to your path

Different from 1 node sample, there are two paths:

d:\ggs

d:\ggt

 

4, Alter database archivelog

Oracle GG need database running on archive mode

Need perform. these commands:

Shutdown immediate;

Startup mount;

Alter database archivelog;

Alter database open;

 

5, Create test user and tables

Create user ggs identified by ggs;

Create user ggt identified by ggt;

Grant dba to ggs;

Grant dba to ggt;

 

Conn ggs/ggs

Create table test1(

Stu_id number(6),

Stu_name varchar2(20),

Stu_pass varchar2(20)

);

 

Conn ggt/ggt;

Create table test1(

Stu_id number(6),

Stu_name varchar2(20),

Stu_pass varchar2(20)

);

 

6, Config golden gate for source

1)       Create file path

Access path d:\ggs

Execute ggsci.exe

In ggsci command,execute:

Create subdirs    ---only for the first config operation

 

2)       Add service for source mgr

Edit the ./GLOBALS:

Edit params ./GLOBALS

Content:

MGRSERVNAME GGMGRS

Under gg path ,execute follow command to add GGMGRS service:

Install addservice

 

3)       Modify params for manager process(mgr)

Edit param mgr

Content:

Port 7500   --set the manager running port

Dynamicportlist 7501-7505

Autorestart extract *,waitminutes 2,retries 5

 

Can use command:

Start mgr

To start the mgr process

Can use command :

Info all

To see the status of mgr running

 

 

4)       Add supplemental logging for source table

 

5)       Add and edit params for extract progress

Command:

Add extract eora,tranlog,begin now

Edit param eora

 

Param Contents:

extract eora

dynamicresolution

userid ggs,password ggs

exttrail d:\ggs\dirdat\et

table ggs.test1;

 

Add remote list

Add rmttrail d:\ggt\dirdat\r1,extract eora,megabyte 100

 

Use command:

Start eora

To start extract eora progress

 

6)       Add and edit pump process param

Add extract pump_so,exttrailsource d:\ggs\dirdat\et

Add remote trail file to extract pump_so:

Add rmttrail d:\ggt\dirdat\et,extract pump_so

Edit param pump_so

pump_so.prm contents:

extract pump_so

Dynamicresolution

Userid ggs,password ggs

rmthost 127.0.0.1, mgrport 7500   --rmthost is remote host’s ip addr

--Setenv(ORACLE_SID=ORCL)

rmttrail d:\ggt\dirdat\et

Table ggs.test1;

 

7)       Start progress

Start extract progress:

Start eora

Start pump progress

Start pump_so

Check the progress running

Info all

 

7, Config golden gate for target:

1)       Create file path

Access path d:\ggt

Execute ggsci.exe

In ggsci command,execute:

Create subdirs    ---only for the first config operation

 

2)       Add service for source mgr

Edit the ./GLOBALS:

Edit params ./GLOBALS

Content:

MGRSERVNAME GGMGRT

Under gg path ,execute follow command to add GGMGRT service:

Install addservice

 

3)       Modify params for manager process(mgr)

Edit param mgr

Content:

port 7600

dynamicportlist 7601-7605

autostart er *

autorestart extract *,waitminutes 2,retries 5

lagreporthours 1

laginfominutes 3

lagcriticalminutes 5

purgeoldextracts d:\ggt\dirdat\et*,usecheckpoints,minkeepdays 3

 

Can use command:

Start mgr

To start the mgr process

Can use command :

Info all

To see the status of mgr running

 

 

4)       Add supplemental logging for target table

 

5)       Add and edit params for replicat progress

Command:

add replicat repl,exttrail d:\ggt\dirdat\et,checkpointtable ggt.checkpoint

Edit param rep1

 

Param Contents:

replicat rep1

ASSUMETARGETDEFS

userid ggt,password ggt

discardfile ./dirrpt/rep1.dsc, append, megabytes 50

--HANDLECOLLISIONS

Dynamicresolution

map ggs.test1, target ggt.test1;

 

6)       Start progress

Start replicat progress

Start rep1

Check the progress running

Info all

 

8, Test

        

Conn ggs/ggs

Insert into test1 select 1,’aa’,’pass1’ from dual;

Insert into test1 select 2,’bb’,’pass2’ from dual;

Commit;

 

few seconds later:

conn ggt/ggt

select * from test1;

 

 

 

 

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

转载于:http://blog.itpub.net/16179598/viewspace-758544/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值