【GoldenGate】Oracle GoldenGate(二) 雙向同步配置

海星星hktk發表於2014-10-06

Oracle GoldenGate 雙向同步配置

[專案環境]

Item

Primary System

Secondary System

Platform

RHEL5.5

RHEL5.5

Hostname

lvxinghao1

lvxinghao2

Database

Oracle10.2.0.1

Oracle 10.2.0.1

Character Set

ZHS16GBK

ZHS16GBK

ORACLE_SID

prod

test1

Listener Name/Port

LISTENER/1521

LISTENER/1521

Goldengate User

ogg

ogg

[實施步驟]


1       Oracle GoldenGateActive-Active


在前面已經配置好prod to test1 單向複製

下面在單向複製的基礎上配置雙向複製:SourceDB:test1Target DB:prod

Item

Source System

Target System

Platform

RHEL5.5

RHEL5.5

Hostname

lvxinghao2

lvxinghao1

Database

Oracle 10.2.0.1

Oracle 10.2.0.1

Character Set

ZHS16GBK

ZHS16GBK

ORACLE_SID

test1

prod

Listener Name/Port

LISTENER/1521

LISTENER/1521

Goldengate User

ogg

ogg

 

2       Configure Oracle Database for Goldengate

2.1     Create Goldengate user

Grant appropriate privileges.

ogg使用者在單向複製中已經建立,下面賦予相應許可權。

For Source System:

[oracle@lvxinghao2 ~]$ sqlplus '/as sysdba'

 

SYS@ test1>grant alter any table to ogg;

SYS@ test1>grant flashback any table to ogg;

SYS@ test1>grant execute on dbms_flashback to ogg;

 

SCOTT@ test1>grant insert, update, delete on scott.emp to ogg;

SCOTT@ test1>grant insert, update, delete on scott.dept to ogg;

 

 

For Target System:

SYS@ prod>grant create table to ogg;

grant DML privilege to Goldengate user:

SYS@ prod>conn scott/tiger

SCOTT@ prod>grant insert, update, delete on scott.lvxinghao to ogg;

 

SCOTT@ prod>grant insert, update, delete on scott.emp to ogg;

SCOTT@ prod>grant insert, update, delete on scott.dept to ogg;

 

2.2     Enable supplemental log mode in source system

Check supplemental log mode is enabled or not by following query:

SYS@ test1>select supplemental_log_data_min from v$database;

SUPPLEMENTAL_LOG_DATA_MIN

--------------------------------------------------

NO

If not, enable it:

SYS@ test1> alter database add supplemental log data;

SYS@ test1> alter system switch logfile;

2.3     Enable archive log mode in source system

Enable archive log mode:

SYS@ test1> alter system set log_archive_dest_1='location=/disk1/arch1';

SYS@ test1> shutdown immediate

SYS@ test1> startup mount

SYS@ test1> alter database archivelog;

SYS@ test1> alter database open;

Check database archive log information:

SYS@ test1>alter system archive log current;

System altered.

 

SYS@ test1>archive log list;

Database log mode              Archive Mode

Automatic archival             Enabled

Archive destination            /disk1/arch1

Oldest online log sequence     10

Next log sequence to archive   12

Current log sequence           12

2.4     Enable force logging mode in source system

Enable force logging mode:

SYS@ test1> alter database force logging;

Check force logging mode is enabled or not by following query:

SYS@ test1>select force_logging from v$database;

FORCE_LOGGING

--------------------

YES

Enable transaction data change capture for these two tables in Source system:

GGSCI (lvxinghao2) 1> DBLOGIN USERID ogg, PASSWORD ogg

Successfully logged into database.

 

GGSCI (lvxinghao2) 2> ADD TRANDATA scott.*

Logging of supplemental redo data enabled for table SCOTT.*.

Verify that supplemental logging has been turned on for these tables.

GGSCI (lvxinghao2) 11> INFO TRANDATA scott.*

Logging of supplemental redo log data is enabled for table SCOTT.BONUS

Logging of supplemental redo log data is enabled for table SCOTT.DEPT

Logging of supplemental redo log data is enabled for table SCOTT.EMP

Logging of supplemental redo log data is enabled for table SCOTT.LVXINGHAO

Logging of supplemental redo log data is enabled for table SCOTT.SALGRADE

3       Configure Extract Process in Source system

3.1     Edit extract process parameter sourceDB也需要修改

GGSCI (lvxinghao2) 15> edit params eora_2

Add:

-- Change Capture parameter file to capture

--sscott.* changes

EXTRACT EORA_2

SETENV (NLS_LANG=AMERICAN_AMERICA.ZHS16GBK)

USERID ogg, PASSWORD ogg

TRANLOGOPTIONS EXCLUDEUSER ogg

EXTTRAIL ./dirdat/ab

TABLE scott.*;

Please note that “ab” is prefix for local trail file.

Execute the following commands in source system to add Primary Extract group.

GGSCI (lvxinghao2) 16> add extract eora_2,tranlog,begin now

EXTRACT added.

3.2     Define GoldenGate local trail

GGSCI (lvxinghao2) 17> ADD EXTTRAIL ./dirdat/ab, EXTRACT EORA_2, MEGABYTES 5

EXTTRAIL added.

3.3     Start primary Extract process

GGSCI (lvxinghao2) 18> start extract eora_2

Sending START request to MANAGER ...

EXTRACT EORA_12 starting

Verify extract process is running or not:

GGSCI (lvxinghao2) 13> info extract eora_2

 

EXTRACT    EORA_2    Last Started 2014-09-14 00:16   Status RUNNING

Checkpoint Lag       00:17:32 (updated 00:00:09 ago)

Log Read Checkpoint  Oracle Redo Logs

                     2014-09-13 23:59:21  Seqno 12, RBA 76816

Now Goldengate will generate local tail file “ab000000” under dirdat in Source system:

[oracle@lvxinghao2 ogg]$ ll /u01/app/ogg/dirdat/

total 8

-rw-rw-rw- 1 oracle oinstall  912 Sep 14 00:16 ab000000

-rw-rw-rw- 1 oracle oinstall 2469 Sep 13 21:29 pa000000

4       Configure pump process in source system

4.1     Edit data pump process parameter

GGSCI (lvxinghao2) 20> edit params pora_2

Add:

-- Data Pump parameter file to read the local

-- trail of scott.* changes

EXTRACT PORA_2

SETENV (NLS_LANG=AMERICAN_AMERICA.ZHS16GBK)

PASSTHRU

RMTHOST lvxinghao1, MGRPORT 7809

RMTTRAIL ./dirdat/pb

TABLE scott.*;

Add data pump Extract group

GGSCI (lvxinghao2) 21> add extract pora_2,exttrailsource ./dirdat/ab

EXTRACT added.

Verify results:

GGSCI (lvxinghao2) 22> info extract pora_2

 

EXTRACT    PORA_2    Initialized   2014-09-14 00:29   Status STOPPED

Checkpoint Lag       00:00:00 (updated 00:00:07 ago)

Log Read Checkpoint  File ./dirdat/ab000000

                     First Record  RBA 0

4.2     Add GoldenGate remote trail in Source system

GGSCI (lvxinghao2) 24> add rmttrail ./dirdat/pb,extract pora_2,megabytes 5

RMTTRAIL added.

Start data pump process:

GGSCI (lvxinghao2) 25> start extract pora_2

Sending START request to MANAGER ...

EXTRACT PORA_2 starting

Verify the results:

GGSCI (lvxinghao2) 36> INFO EXTRACT PORA_2

 

EXTRACT    PORA_2    Last Started 2014-09-14 00:30   Status RUNNING

Checkpoint Lag       00:00:00 (updated 00:00:47 ago)

Log Read Checkpoint  File ./dirdat/ab000000

                     First Record  RBA 0

Now Goldengate will generate remote tail file “pb000000” under dirdat in Target system:

[oracle@lvxinghao1 ~]$ ll /u01/app/ogg/dirdat/

-rw-rw-rw- 1 oracle oinstall 2432 Sep 14 00:56 aa000000

-rw-rw-rw- 1 oracle oinstall 1740 Sep 14 03:25 pb000000

5       Configure replicat process in target system

5.1     Create GLOBALS parameter in target system

Edit GLOBALS(upper case) parameter file to indicate checkpoint table

GGSCI (lvxinghao1) 11> edit params ./GLOBALS

Add:

CHECKPOINTTABLE ogg.ggschkpt

Verify:

[oracle@lvxinghao1 ogg]$ ll GLOBALS

-rw-rw-rw- 1 oracle oinstall 29 Sep 13 21:04 GLOBALS

For GLOBALS configuration take effect, we must exit GGSCI session:

GGSCI (lvxinghao1) 13> exit

Add replicat checkpoint table in target system:

GGSCI (lvxinghao1) 1> DBLOGIN USERID ogg, PASSWORD ogg

Successfully logged into database.

 

GGSCI (lvxinghao1) 2> ADD CHECKPOINTTABLE

No checkpoint table specified, using GLOBALS specification (ogg.ggschkpt)...

Successfully created checkpoint table OGG.GGSCHKPT.

5.2     Edit Delivery process parameter

Add Replicat group:

GGSCI (lvxinghao1) 3>ADD REPLICAT RORA_2, EXTTRAIL ./dirdat/pb

REPLICAT added.

Edit replicat process RORA_1 parameter:

GGSCI (lvxinghao1) 4> EDIT PARAM RORA_2

Add:

--

-- Change Delivery parameter file to apply

-- lvxinghao Changes

--

REPLICAT RORA_2

SETENV (NLS_LANG=AMERICAN_AMERICA.ZHS16GBK)

USERID ogg, PASSWORD ogg

HANDLECOLLISIONS

ASSUMETARGETDEFS

DISCARDFILE ./dirrpt/RORA_ab.DSC, PURGE

MAP scott.*, TARGET scott.*;

Note: In the MAP statement, the first owner/schema is for the source and the second for the target.

Start Replicat process:

GGSCI (lvxinghao1) 5> START REPLICAT RORA_2

Sending START request to MANAGER ...

REPLICAT RORA_2 starting

Verify:

GGSCI (lvxinghao1) 6> info replicat rora_2

 

REPLICAT   RORA_1    Last Started 2014-09-13 21:09   Status RUNNING

Checkpoint Lag       00:00:00 (updated 00:00:07 ago)

Log Read Checkpoint  File ./dirdat/pa000000

                     First Record  RBA 0

6       Check process status

6.1     prod

GGSCI (lvxinghao1) 15> info all

Program     Status      Group       Lag           Time Since Chkpt

MANAGER     RUNNING                                          

EXTRACT     RUNNING     EORA_1      00:00:00      00:00:03   

EXTRACT     RUNNING     PORA_1      00:00:00      00:00:06   

REPLICAT    RUNNING     RORA_2      00:00:00      00:00:04   

 

GGSCI (lvxinghao1) 16> info extract eora_1

EXTRACT    EORA_1    Last Started 2014-09-14 11:39   Status RUNNING

Checkpoint Lag       00:00:00 (updated 00:00:03 ago)

Log Read Checkpoint  Oracle Redo Logs

                     2014-09-14 14:22:31  Seqno 27, RBA 6425088

 

GGSCI (lvxinghao1) 17> info extract pora_1

EXTRACT    PORA_1    Last Started 2014-09-14 11:39   Status RUNNING

Checkpoint Lag       00:00:00 (updated 00:00:06 ago)

Log Read Checkpoint  File ./dirdat/aa000005

                     2014-09-14 12:27:18.000000  RBA 1689

 

GGSCI (lvxinghao1) 19> info replicat rora_2

REPLICAT   RORA_2    Last Started 2014-09-14 11:39   Status RUNNING

Checkpoint Lag       00:00:00 (updated 00:00:02 ago)

Log Read Checkpoint  File ./dirdat/pb000002

                     2014-09-14 12:25:46.353006  RBA 988

 

6.2     test1

GGSCI (lvxinghao2) 18> info all

Program     Status      Group       Lag           Time Since Chkpt

MANAGER     RUNNING                                           

EXTRACT     RUNNING     EORA_2      00:00:00      00:00:08   

EXTRACT     RUNNING     PORA_2      00:00:00      00:00:02   

REPLICAT    RUNNING     RORA_1      00:00:00      00:00:03   

 

GGSCI (lvxinghao2) 19> info extract eora_2

EXTRACT    EORA_2    Last Started 2014-09-14 11:51   Status RUNNING

Checkpoint Lag       00:00:00 (updated 00:00:07 ago)

Log Read Checkpoint  Oracle Redo Logs

                     2014-09-14 14:26:16  Seqno 13, RBA 2754560

 

GGSCI (lvxinghao2) 20> info extract pora_2

EXTRACT    PORA_2    Last Started 2014-09-14 11:39   Status RUNNING

Checkpoint Lag       00:00:00 (updated 00:00:07 ago)

Log Read Checkpoint  File ./dirdat/ab000005

                     2014-09-14 12:25:46.000000  RBA 1333

 

GGSCI (lvxinghao2) 21> info replicat rora_1

REPLICAT   RORA_1    Last Started 2014-09-14 11:51   Status RUNNING

Checkpoint Lag       00:00:00 (updated 00:00:07 ago)

Log Read Checkpoint  File ./dirdat/pa000004

                     2014-09-14 12:27:17.648635  RBA 1285

 

7       Verify if DML can be duplicated correctly

7.1     Table:lvxinghao

Insert data in source system:

SYS@ test1>conn scott/tiger

SCOTT@ test1> INSERT INTO lvxinghao

VALUES(8002,'Damon2','CLERK',7902,sysdate,800,100,20);

SCOTT@ test1> INSERT INTO lvxinghao

VALUES(8003,'Elena2','CLERK',7698,sysdate,600,200,30);

 

SCOTT@ test1> commit;

Check the result in target system:

SCOTT@ test1>select * from lvxinghao;

SCOTT@ test1>select * from lvxinghao order by 1;

 

 EMPNO ENAME   JOB          MGR HIREDATE     SAL  COMM  DEPTNO

------ ------- --------- ------ --------- ------ ----- -------

  7782 CLARK   MANAGER     7839 09-JUN-81   2450            10

  7788 lxh     ANALYST     7566 19-APR-87   3000            20

  7839 KING    PRESIDENT        17-NOV-81   5000            10

  7844 TURNER  SALESMAN    7698 08-SEP-81   1500     0      30

  7876 ADAMS   CLERK       7788 23-MAY-87   1100            20

  7900 JAMES   CLERK       7698 03-DEC-81    950            30

  7902 FORD    ANALYST     7566 03-DEC-81   3000            20

  7934 MILLER  CLERK       7782 23-JAN-82   1300            10

  8000 Damon   CLERK       7902 13-SEP-14    800   100      20

  8001 Elena   CLERK       7698 13-SEP-14    600   200      30

  8002 Damon2  CLERK       7902 14-SEP-14    800   100      20

  8003 Elena2  CLERK       7698 14-SEP-14    600   200      30

 

 

SCOTT@ prod>select * from lvxinghao order by 1;

 

 EMPNO ENAME   JOB          MGR HIREDATE               SAL  COMM  DEPTNO

------ ------- --------- ------ ------------------- ------ ----- -------

  7782 CLARK   MANAGER     7839 1981-06-09 00:00:00   2450            10

  7788 lxh     ANALYST     7566 1987-04-19 00:00:00   3000            20

  7839 KING    PRESIDENT        1981-11-17 00:00:00   5000            10

  7844 TURNER  SALESMAN    7698 1981-09-08 00:00:00   1500     0      30

  7876 ADAMS   CLERK       7788 1987-05-23 00:00:00   1100            20

  7900 JAMES   CLERK       7698 1981-12-03 00:00:00    950            30

  7902 FORD    ANALYST     7566 1981-12-03 00:00:00   3000            20

  7934 MILLER  CLERK       7782 1982-01-23 00:00:00   1300            10

  8000 Damon   CLERK       7902 2014-09-13 21:15:41    800   100      20

  8001 Elena   CLERK       7698 2014-09-13 21:17:22    600   200      30

  8002 Damon2  CLERK       7902 2014-09-14 03:33:03    800   100      20

  8003 Elena2  CLERK       7698 2014-09-14 03:33:13    600   200      30

 

12 rows selected.

Update operation prod to test1

Update data:

SCOTT@ prod>update lvxinghao set ename='lvxh' where empno=7782;

SCOTT@ test1>commit;

Check the result in target system:

SCOTT@ test1>select * from lvxinghao order by 1;

 

 EMPNO ENAME   JOB          MGR HIREDATE     SAL  COMM  DEPTNO

------ ------- --------- ------ --------- ------ ----- -------

  7782 lvxh    MANAGER     7839 09-JUN-81   2450            10

  7788 lxh     ANALYST     7566 19-APR-87   3000            20

  7839 KING    PRESIDENT        17-NOV-81   5000            10

  7844 TURNER  SALESMAN    7698 08-SEP-81   1500     0      30

  7876 ADAMS   CLERK       7788 23-MAY-87   1100            20

  7900 JAMES   CLERK       7698 03-DEC-81    950            30

  7902 FORD    ANALYST     7566 03-DEC-81   3000            20

  7934 MILLER  CLERK       7782 23-JAN-82   1300            10

  8000 Damon   CLERK       7902 13-SEP-14    800   100      20

  8001 Elena   CLERK       7698 13-SEP-14    600   200      30

  8002 Damon2  CLERK       7902 14-SEP-14    800   100      20

  8003 Elena2  CLERK       7698 14-SEP-14    600   200      30

 

12 rows selected.

 

7.2     Table:emp

prod inserttest1 check;

test1 deleteprod check;

SCOTT@ prod>INSERT INTO emp          

  2  VALUES(8000,'Damon','CLERK',7902,sysdate,800,100,20);

 

SCOTT@ prod>INSERT INTO emp

  2  VALUES(8001,'Elena','CLERK',7698,sysdate,600,200,30);

 

SCOTT@ prod>commit;

 

SCOTT@ test1>select * from emp;

 EMPNO ENAME   JOB          MGR HIREDATE     SAL   COMM  DEPTNO

------ ------- --------- ------ --------- ------ ------ -------

  8000 Damon   CLERK       7902 14-SEP-14    800    100      20

  8001 Elena   CLERK       7698 14-SEP-14    600    200      30

  7369 SMITH   CLERK       7902 17-DEC-80    800             20

  7499 ALLEN   SALESMAN    7698 20-FEB-81   1600    300      30

  7521 WARD    SALESMAN    7698 22-FEB-81   1250    500      30

  7566 JONES   MANAGER     7839 02-APR-81   2975             20

  7654 MARTIN  SALESMAN    7698 28-SEP-81   1250   1400      30

  7698 BLAKE   MANAGER     7839 01-MAY-81   2850             30

  7782 CLARK   MANAGER     7839 09-JUN-81   2450             10

  7788 SCOTT   ANALYST     7566 19-APR-87   3000             20

  7839 KING    PRESIDENT        17-NOV-81   5000             10

  7844 TURNER  SALESMAN    7698 08-SEP-81   1500      0      30

  7876 ADAMS   CLERK       7788 23-MAY-87   1100             20

  7900 JAMES   CLERK       7698 03-DEC-81    950             30

  7902 FORD    ANALYST     7566 03-DEC-81   3000             20

  7934 MILLER  CLERK       7782 23-JAN-82   1300             10

16 rows selected.

SCOTT@ test1>

 

SCOTT@ test1>delete from emp where empno>=8000;

SCOTT@ test1>commit;

SCOTT@ prod>select * from emp;

 EMPNO ENAME   JOB          MGR HIREDATE               SAL   COMM  DEPTNO

------ ------- --------- ------ ------------------- ------ ------ -------

  7788 SCOTT   ANALYST     7566 1987-04-19 00:00:00   3000             20

  7839 KING    PRESIDENT        1981-11-17 00:00:00   5000             10

  7844 TURNER  SALESMAN    7698 1981-09-08 00:00:00   1500      0      30

  7876 ADAMS   CLERK       7788 1987-05-23 00:00:00   1100             20

  7900 JAMES   CLERK       7698 1981-12-03 00:00:00    950             30

  7902 FORD    ANALYST     7566 1981-12-03 00:00:00   3000             20

  7934 MILLER  CLERK       7782 1982-01-23 00:00:00   1300             10

  7369 SMITH   CLERK       7902 1980-12-17 00:00:00    800             20

  7499 ALLEN   SALESMAN    7698 1981-02-20 00:00:00   1600    300      30

  7521 WARD    SALESMAN    7698 1981-02-22 00:00:00   1250    500      30

  7566 JONES   MANAGER     7839 1981-04-02 00:00:00   2975             20

  7654 MARTIN  SALESMAN    7698 1981-09-28 00:00:00   1250   1400      30

  7698 BLAKE   MANAGER     7839 1981-05-01 00:00:00   2850             30

  7782 CLARK   MANAGER     7839 1981-06-09 00:00:00   2450             10

14 rows selected.

 

SCOTT@ prod>

 

7.3     Table:dept

prod insert test1 check;

test1 updateprod check;

prod deletetest1 check;

SCOTT@ prod>insert into dept values(50,'DBA','BEIJING');

SCOTT@ prod>commit;

 

SCOTT@ test1>select * from dept;

 

 DEPTNO DNAME          LOC

------- -------------- -------------

     50 DBA            BEIJING

     10 ACCOUNTING     NEW YORK

     20 RESEARCH       DALLAS

     30 SALES          CHICAGO

     40 OPERATIONS     BOSTON

 

SCOTT@ test1>update dept set dname='IT' where deptno=50;

SCOTT@ test1>commit;

SCOTT@ prod>select * from dept;

 DEPTNO DNAME          LOC

------- -------------- -------------

     50 IT             BEIJING

     10 ACCOUNTING     NEW YORK

     20 RESEARCH       DALLAS

     30 SALES          CHICAGO

     40 OPERATIONS     BOSTON

 

 

SCOTT@ prod>delete from dept where deptno=50;

SCOTT@ prod>commit;

SCOTT@ test1>select * from dept;

 

 DEPTNO DNAME          LOC

------- -------------- -------------

     10 ACCOUNTING     NEW YORK

     20 RESEARCH       DALLAS

     30 SALES          CHICAGO

     40 OPERATIONS     BOSTON

 

8       Show parameters

8.1     prod:mgreora_1pora_1rora_2

 

GGSCI (lvxinghao1) 8> info all

Program     Status      Group       Lag           Time Since Chkpt

MANAGER     RUNNING                                          

EXTRACT     RUNNING     EORA_1      00:00:00      00:00:02   

EXTRACT     RUNNING     PORA_1      00:00:00      00:00:10   

REPLICAT    RUNNING     RORA_2      00:00:00      00:00:07

 

GGSCI (lvxinghao1) 45> view params mgr

PORT 7809

PURGEOLDEXTRACTS ./dirdat, USECHECKPOINTS

 

GGSCI (lvxinghao1) 46> view params eora_1

-- Change Capture parameter file to capture

--scott.* changes

EXTRACT EORA_1

SETENV (NLS_LANG=AMERICAN_AMERICA.ZHS16GBK)

USERID ogg, PASSWORD ogg

TRANLOGOPTIONS EXCLUDEUSER ogg

EXTTRAIL ./dirdat/aa

TABLE scott.*;

 

GGSCI (lvxinghao1) 47> view params pora_1

-- Data Pump parameter file to read the local

-- trail of lvxinghao changes

EXTRACT PORA_1

SETENV (NLS_LANG=AMERICAN_AMERICA.ZHS16GBK)

PASSTHRU

RMTHOST lvxinghao2, MGRPORT 7809

RMTTRAIL ./dirdat/pa

TABLE scott.*;

 

GGSCI (lvxinghao1) 49> view params rora_2

-- Change Delivery parameter file to apply

-- lvxinghao Changes

REPLICAT RORA_2

SETENV (NLS_LANG=AMERICAN_AMERICA.ZHS16GBK)

USERID ogg, PASSWORD ogg

HANDLECOLLISIONS

ASSUMETARGETDEFS

DISCARDFILE ./dirrpt/RORA_ab.DSC, PURGE

MAP scott.*, TARGET scott.*;

 

8.2     test1:mgreora_2pora_2rora_1

GGSCI (lvxinghao2) 9> info all

Program     Status      Group       Lag           Time Since Chkpt

MANAGER     RUNNING                                          

EXTRACT     RUNNING     EORA_2      00:00:00      00:00:06   

EXTRACT     RUNNING     PORA_2      00:00:00      07:12:24   

REPLICAT    RUNNING     RORA_1      07:18:47      00:00:01

GGSCI (lvxinghao2) 39> view params mgr

PORT 7809

PURGEOLDEXTRACTS /u01/app/ogg/dirdat, USECHECKPOINTS

 

GGSCI (lvxinghao2) 40> view params eora_2

-- Change Capture parameter file to capture

--scott.* changes

EXTRACT EORA_2

SETENV (NLS_LANG=AMERICAN_AMERICA.ZHS16GBK)

USERID ogg, PASSWORD ogg

TRANLOGOPTIONS EXCLUDEUSER ogg

EXTTRAIL ./dirdat/ab

TABLE scott.*;

 

GGSCI (lvxinghao2) 41> view params pora_2

-- Data Pump parameter file to read the local

-- trail of scott.* changes

EXTRACT PORA_2

SETENV (NLS_LANG=AMERICAN_AMERICA.ZHS16GBK)

PASSTHRU

RMTHOST lvxinghao1,MGRPORT 7809

RMTTRAIL ./dirdat/pb

TABLE scott.*;

 

GGSCI (lvxinghao2) 42> view params rora_1

-- Change Delivery parameter file to apply

-- lvxinghao Changes

REPLICAT RORA_1

SETENV (NLS_LANG=AMERICAN_AMERICA.ZHS16GBK)

USERID ogg, PASSWORD ogg

HANDLECOLLISIONS

ASSUMETARGETDEFS

DISCARDFILE ./dirrpt/RORA_aa.DSC, PURGE

MAP scott.*, TARGET scott.*;

 

 

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/29475508/viewspace-1290163/,如需轉載,請註明出處,否則將追究法律責任。

相關文章