GoldenGate for win安裝配置
1.GoldenGate軟體的安裝:
下載windows版的GoldenGate介質——V18162-01.zip,解壓到ggs目錄
C:\>cd ggs
C:\ggs>install addservice addevents
Oracle GoldenGate messages installed successfully.
Service 'GGSMGR' created.
Install program terminated normally.
C:\ggs>ggsci
Oracle GoldenGate Command Interpreter for Oracle
Version 10.4.0.19 Build 002
Windows (optimized), Oracle 10 on Sep 18 2009 15:54:55
Copyright (C) 1995, 2009, Oracle and/or its affiliates. All rights reserved.
GGSCI (wangyj) 1> create subdirs
Creating subdirectories under current directory C:\ggs
Parameter files C:\ggs\dirprm: created
Report files C:\ggs\dirrpt: created
Checkpoint files C:\ggs\dirchk: created
Process status files C:\ggs\dirpcs: created
SQL script. files C:\ggs\dirsql: created
Database definitions files C:\ggs\dirdef: created
Extract data files C:\ggs\dirdat: created
Temporary files C:\ggs\dirtmp: created
Veridata files C:\ggs\dirver: created
Veridata Lock files C:\ggs\dirver\lock: created
Veridata Out-Of-Sync files C:\ggs\dirver\oos: created
Veridata Out-Of-Sync XML files C:\ggs\dirver\oosxml: created
Veridata Parameter files C:\ggs\dirver\params: created
Veridata Report files C:\ggs\dirver\report: created
Veridata Status files C:\ggs\dirver\status: created
Veridata Trace files C:\ggs\dirver\trace: created
Stdout files C:\ggs\dirout: created
2.環境資訊
source:
OS wangyj
ip 192.168.234.1
sid orcl
dml schema ggs
ddl schema ggsddl
GoldenGate C:\ggs
target:
OS byfree_x64
ip 192.168.234.112
sid orcl2
dml schema ggs
ddl schema ggsddl
GoldenGate C:\ggs
檢查source和target DB最小附加日誌模式:
SQL> select SUPPLEMENTAL_LOG_DATA_MIN from v$database;
SUPPLEME
--------
YES
如果沒有開啟資料庫的最小附加日誌,則透過以下語句開啟
SQL> alter database add supplemental log data;
3.source的設定(DML)
To capture key values with ADD TRANDATA
C:\ggs>ggsci
GGSCI (wangyj) 1> dblogin userid ggs password ggs
GGSCI (wangyj) 2> add trandata ggs.*
GGSCI (wangyj) 3> edit param mgr (ggs服務埠設定)
輸入:port 7809
GGSCI (wangyj) 4> add extract ext1,tranlog,begin now
GGSCI (wangyj) 5> edit param ext1 (ext1必須與上一命令使用相同名稱——extract程式)
輸入如下內容:
extract ext1
userid ggs,password ggs
rmthost 192.168.234.112, mgrport 7809
rmttrail c:\ggs\dirdat\r1
dynamicresolution
gettruncates
table ggs.*;
(以上設定的兩個引數檔案預設放置於C:\ggs\dirprm中)
GGSCI (wangyj) 6> add rmttrail C:\ggs\dirdat\r1 extract ext1
GGSCI (wangyj) 7> start mgr
GGSCI (wangyj) 8> start ext1
檢視程式的執行情況
GGSCI (wangyj) 9> info all
Program Status Group Lag Time Since Chkpt
MANAGER RUNNING
EXTRACT RUNNING EXT1 00:00:00 95:14:49
這裡的RUNNING分別表示ggs服務和捕獲程式執行正常。如沒正常RUNNING,可檢視C:\ggs\ggserr.log日誌。
4.target的設定(DML)
GGSCI (byfree_x64) 1> edit param mgr
輸入如下內容:
PORT 7809
DYNAMICPORTLIST 7840-7850
GGSCI (byfree_x64) 2> ADD replicat rep1 EXTTRAIL c:\ggs\dirdat\r1,nodbcheckpoint
GGSCI (byfree_x64) 3> edit param rep1
輸入如下內容:
replicat rep1
userid ggs,password ggs
assumetargetdefs
reperror default,discard
discardfile c:\oradata\repsz.dsc,append,megabytes 100
map ggs.*, target ggs.*;
GGSCI (byfree_x64) 4> start mgr
GGSCI (byfree_x64) 5> start rep1
GGSCI (byfree_x64) 6> info all
Program Status Group Lag Time Since Chkpt
MANAGER RUNNING
REPLICAT RUNNING REP1 00:00:00 92:06:53
如沒正常RUNNING,可檢視C:\ggs\ggserr.log日誌。
至此,GoldenGate的單向DML同步已配置成功,可透過insert into、update等測試同步效果了!
5.source的設定(DDL)
建立ggsddl使用者
GGSCI (wangyj) 1> edit param globals
輸入如下內容:
GGSCHEMA ggsddl
C:\ggs>sqlplus / as sysdba
SQL> @marker_setup.sql
輸入:ggsddl
SQL> @ddl_setup.sql
enter schema:ggsddl
choose installation mode: INITIALSETUP
SQL> @role_setup.sql
SQL> grant GGS_GGSUSER_ROLE to ggsddl;
SQL> @ddl_enable.sql
GGSCI (wangyj) 2> add extract extddl,tranlog,begin now
GGSCI (wangyj) 3> edit param extddl
輸入如下內容:
extract extddl
SETENV (ORACLE_SID=orcl)
userid ggsddl, password ggsddl
rmthost 192.168.234.112, mgrport 7809
rmttrail c:\ggs\dirdat\r1
dynamicresolution
gettruncates
DDL include all
table ggsddl.*;
GGSCI (wangyj) 4> start extddl (開啟ddl捕獲程式)
GGSCI (wangyj) 5> info all
Program Status Group Lag Time Since Chkpt
MANAGER RUNNING
EXTRACT RUNNING EXTDDL 00:00:00 95:14:49
如沒正常RUNNING,可檢視C:\ggs\ggserr.log日誌。
6.target的設定(DDL)
建立ggsddl使用者
GGSCI (byfree_x64) 1> edit param globals
輸入如下內容:
GGSCHEMA ggsddl
GGSCI (byfree_x64) 2> ADD replicat repddl EXTTRAIL c:\ggs\dirdat\r1,nodbcheckpoint
GGSCI (byfree_x64) 3> edit param repddl
輸入如下內容:
replicat repddl
userid ggsddl,password ggsddl
assumetargetdefs
reperror default,discard
ddl include all
discardfile c:\oradata\repddl.dsc,append,megabytes 100
map ggsddl.*, target ggsddl.*;
GGSCI (byfree_x64) 4> start repddl
GGSCI (byfree_x64) 5> info all
Program Status Group Lag Time Since Chkpt
MANAGER RUNNING
REPLICAT RUNNING REPDDL 00:00:00 92:06:53
如沒正常RUNNING,可檢視C:\ggs\ggserr.log日誌。
完成第5、6步的配置,即可測試DDL SQL。
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/21754115/viewspace-1752512/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- Oracle goldengate 安裝配置OracleGo
- 安裝並配置goldengateGo
- GOLDENGATE安裝和配置手冊Go
- 【GoldenGate】Oracle GoldenGate Veridata 安裝配置與應用GoOracle
- GoldenGate的安裝、配置與測試Go
- 解除安裝goldengate相關配置資訊Go
- 【GoldenGate】Oracle GoldenGate(一) 安裝與DML單向同步配置GoOracle
- GOLDENGATE安裝和配置手冊總結Go
- 安裝GoldenGateGo
- GoldenGate抽取Informix資料庫安裝及配置GoORM資料庫
- 安裝配置Oracle GoldenGate for DB2(單向)OracleGoDB2
- Goldengate Veridata 11.2 for linux安裝配置GoLinux
- 解除安裝goldengateGo
- Oracle GoldenGate安裝(一)OracleGo
- Oracle GoldenGate安裝(二)OracleGo
- Oracle GoldenGate安裝(三)OracleGo
- GoldenGate安裝簡記Go
- 解除安裝Oracle GoldenGateOracleGo
- Oracle GoldenGate Veridata 12.2.1.4安裝配置使用全手冊OracleGo
- goldengate學習-安裝篇Go
- Linux下安裝GoldenGateLinuxGo
- Mysql安裝與配置_win10MySqlWin10
- Linux下解除安裝GoldenGateLinuxGo
- Oracle GoldenGate安裝初體驗OracleGo
- PHP7安裝配置(win10)PHPWin10
- 安裝win10系統的配置要求是什麼 win10系統安裝最低配置要求Win10
- 實戰goldengate:安裝配置+資料初始化+單向DML複製Go
- Oracle GoldenGate在RAC上部署安裝OracleGo
- goldengate在linux上的安裝GoLinux
- Win 10 環境配置VirtualBox安裝UbuntuUbuntu
- 繼續配置win10安裝環境Win10
- Apache伺服器安裝及配置(win版)Apache伺服器
- win10 免安裝版本的MySQL的下載安裝和配置Win10MySql
- win10怎麼看gcc安裝成功_win10安裝和配置GCC的方法Win10GC
- 本地windows搭建spark環境,安裝與詳細配置(jdk安裝與配置,scala安裝與配置,hadoop安裝與配置,spark安裝與配置)WindowsSparkJDKHadoop
- Oracle GoldenGate相關講解及安裝OracleGo
- Oracle GoldenGate系統之----安裝及使用OracleGo
- Goldengate 基本配置Go