728x90

* extract, replicat process DDL parameter 주석처리 or 삭제

 

$sqlplus / as sysdba

SQL*Plus: Release 19.0.0.0.0 - Production on Thu Jan 13 02:42:06 2022
Version 19.13.0.0.0
Copyright (c) 1982, 2021, Oracle.  All rights reserved.
Connected to:
Oracle Database 19c Standard Edition 2 Release 19.0.0.0.0 - Production
Version 19.13.0.0.0

SQL> @ddl_disable
Trigger altered.

SQL> @ddl_remove
DDL replication removal script.
WARNING: this script removes all DDL replication objects and data.
You will be prompted for the name of a schema for the Oracle GoldenGate database objects.
NOTE: The schema must be created prior to running this script.
Enter Oracle GoldenGate schema name:oggs
Working, please wait ...
Spooling to file ddl_remove_spool.txt
Script complete.

SQL> select object_name from all_objects where object_type='TABLE' and owner='OGGS';

OBJECT_NAME
--------------------------------------------------------------------------------
GGS_DDL_RULES
GGS_DDL_RULES_LOG
GGS_MARKER
GGS_STICK
GGS_TEMP_COLS
TCUSTMER
TCUSTORD
7 rows selected.

SQL> @marker_remove

Marker removal script.
WARNING: this script removes all marker objects and data.
You will be prompted for the name of a schema for the Oracle GoldenGate database objects.
NOTE: The schema must be created prior to running this script.
Enter Oracle GoldenGate schema name:oggs
PL/SQL procedure successfully completed.

DROP SEQUENCE "OGGS" ."GGS_MARKER_SEQ"
                      *
ERROR at line 1:
ORA-02289: sequence does not exist

DROP TABLE "OGGS" ."GGS_MARKER"
                   *
ERROR at line 1:
ORA-00942: table or view does not exist
Script complete.

 

SQL> @ddl_status
Please enter the name of a schema for the GoldenGate database objects:
oggs

Setting schema name to OGGS

CLEAR_TRACE STATUS:

Line/pos
----------------------------------------
Error
-----------------------------------------------------------------
No errors
No errors

CREATE_TRACE STATUS:

Line/pos
----------------------------------------
Error
-----------------------------------------------------------------
No errors
No errors

TRACE_PUT_LINE STATUS:

Line/pos
----------------------------------------
Error
-----------------------------------------------------------------
No errors
No errors

INITIAL_SETUP STATUS:

Line/pos
----------------------------------------
Error
-----------------------------------------------------------------
No errors
No errors

DDLVERSIONSPECIFIC PACKAGE STATUS:

Line/pos
----------------------------------------
Error
-----------------------------------------------------------------
No errors
No errors

DDLREPLICATION PACKAGE STATUS:

Line/pos
----------------------------------------
Error
-----------------------------------------------------------------
No errors
No errors

DDLREPLICATION PACKAGE BODY STATUS:

Line/pos
----------------------------------------
Error
-----------------------------------------------------------------
No errors
No errors

DDL IGNORE TABLE
-----------------------------------
OK

DDL IGNORE LOG TABLE
-----------------------------------
OK

DDLAUX PACKAGE STATUS:

Line/pos
----------------------------------------
Error
-----------------------------------------------------------------
No errors
No errors

DDLAUX PACKAGE BODY STATUS:

Line/pos
----------------------------------------
Error
-----------------------------------------------------------------
No errors
No errors

SYS.DDLCTXINFO PACKAGE STATUS:

Line/pos
----------------------------------------
Error
-----------------------------------------------------------------
No errors
No errors

SYS.DDLCTXINFO PACKAGE BODY STATUS:

Line/pos
----------------------------------------
Error
-----------------------------------------------------------------
No errors
No errors

DDL HISTORY TABLE
-----------------------------------
FAILED: Table does not exist

DDL HISTORY TABLE(1)
-----------------------------------
FAILED: Table does not exist

DDL DUMP TABLES
-----------------------------------
FAILED: Table does not exist

DDL DUMP COLUMNS
-----------------------------------
FAILED: Table does not exist

DDL DUMP LOG GROUPS
-----------------------------------
FAILED: Table does not exist

DDL DUMP PARTITIONS
-----------------------------------
FAILED: Table does not exist

DDL DUMP PRIMARY KEYS
-----------------------------------
FAILED: Table does not exist

DDL SEQUENCE
-----------------------------------
FAILED: Sequence does not exist

GGS_TEMP_COLS
-----------------------------------
OK

GGS_TEMP_UK
-----------------------------------
FAILED: Table does not exist

DDL TRIGGER CODE STATUS:

Line/pos
----------------------------------------
Error
-----------------------------------------------------------------
No errors
No errors

DDL TRIGGER INSTALL STATUS
-----------------------------------
FAILED: Trigger not found
FROM "OGGS" ."GGS_SETUP"
             *
ERROR at line 2:
ORA-00942: table or view does not exist

FROM "OGGS" ."GGS_SETUP"
             *
ERROR at line 2:
ORA-00942: table or view does not exist

FROM "OGGS" ."GGS_SETUP"
             *
ERROR at line 2:
ORA-00942: table or view does not exist

LOCATION OF DDL TRACE FILE
--------------------------------------------------------------------------------
/oracle/base/product/19.3/rdbms/log/ggs_ddl_trace.log

Analyzing installation status...

BEGIN :finalRes := "OGGS" .ddlora_verifyDDL (); END;

                    *
ERROR at line 1:
ORA-06550: line 1, column 21:
PLS-00201: identifier 'OGGS.DDLORA_VERIFYDDL' must be declared
ORA-06550: line 1, column 7:
PL/SQL: Statement ignored

SELECT value "VERSION OF DDL REPLICATION" FROM "OGGS" ."GGS_SETUP" WHERE property='LABEL'
                                                       *
ERROR at line 1:
ORA-00942: table or view does not exist


STATUS OF DDL REPLICATION
--------------------------------------------------------------------------------



728x90

'OGG' 카테고리의 다른 글

[OGG] OGG-01496 Failed to open target trail file  (0) 2022.01.14
[OGG] DDL 설정  (2) 2022.01.13
[OGG] Password 암호화  (0) 2022.01.13
[OGG] Process 변경 및 삭제  (0) 2022.01.13
[OGG] Process 연동  (0) 2022.01.13
728x90
OGG-01496  Failed to open target trail file ./dirdat/rx000000000, at RBA 2492.
 
GGSCI (oggsource) 5> alter pmp01 etrollover   
 
2020-07-29 19:22:11  INFO    OGG-01520  Rollover performed.  For each affected output trail of Version 10 or higher format, after starting the source extract, issue ALTER EXTSEQNO for that trail's reader (either pump EXTRACT or REPLICAT) to move the reader's scan to the new trail file;  it will not happen automatically.
EXTRACT altered.
 
GGSCI (oggsource) 9> info pmp01 detail
 
EXTRACT    PMP01     Last Started 2020-07-29 19:22   Status RUNNING
Checkpoint Lag       00:00:00 (updated 00:00:00 ago)
Process ID           10267
Log Read Checkpoint  File /ogg/oggs/dirdat/ex000000000
                     2020-07-29 18:18:45.134008  RBA 2453
 
  Target Extract Trails:
  Trail Name                                       Seqno        RBA     Max MB Trail Type
  ./dirdat/rx                                          1          0         50 RMTTRAIL  
 
  Extract Source                          Begin             End             
  /ogg/oggs/dirdat/ex000000000            2020-07-29 18:18  2020-07-29 18:18
  /ogg/oggs/dirdat/ex000000000            * Initialized *   2020-07-29 18:18
  /ogg/oggs/dirdat/ex000000000            2020-07-29 18:18  2020-07-29 18:18
  /ogg/oggs/dirdat/ex000000000            2020-07-29 18:18  2020-07-29 18:18
  /ogg/oggs/dirdat/ex000000000            * Initialized *   2020-07-29 18:18
  ./dirdat/ex000000000                    * Initialized *   First Record    
 
Current directory    /ogg/oggs
 
Report file          /ogg/oggs/dirrpt/PMP01.rpt
Parameter file       /ogg/oggs/dirprm/pmp01.prm
Checkpoint file      /ogg/oggs/dirchk/PMP01.cpe
Process file         
Error log            /ogg/oggs/ggserr.log
 
 
GGSCI (oggtarget) 14> stop rep01
 
Sending STOP request to REPLICAT REP01 ...
Request processed.
 
GGSCI (oggtarget) 15> alter rep01 extseqno 1, extrba 0
 
2020-07-30 03:41:27  INFO    OGG-06594  Replicat REP01 has been altered. Even the start up position might be updated, duplicate suppression remains active in next startup. To override duplicate suppression, start REP01 with NOFILTERDUPTRANSACTIONS option.
 
REPLICAT altered.

 

728x90

'OGG' 카테고리의 다른 글

[OGG] DDL Deinstall  (0) 2022.01.14
[OGG] DDL 설정  (2) 2022.01.13
[OGG] Password 암호화  (0) 2022.01.13
[OGG] Process 변경 및 삭제  (0) 2022.01.13
[OGG] Process 연동  (0) 2022.01.13
728x90

GGSCI (single) 1> edit param ./GLOBALS
GGSCHEMA OGGS

SQL> select username, default_tablespace from dba_users where username='OGGS';
USERNAME
--------------------------------------------------------------------------------
DEFAULT_TABLESPACE
------------------------------
OGGS
OGG

SQL> select username from dba_users where default_tablespace='OGG'; -> tablespace를 다른 유저와 공유X
USERNAME
--------------------------------------------------------------------------------
OGGT
OGGS

 

- tablespace 변경

SQL> create tablespace oggt datafile '/oracle/base/oradata/ORCL/oggt.dbf' size 100M autoextend on;
Tablespace created.

SQL> alter user OGGT default tablespace oggt;
User altered.

SQL> select username from dba_users where default_tablespace='OGGT';
USERNAME
--------------------------------------------------------------------------------
OGGT


$sqlplus / as sysdba

SQL> @marker_setup
Marker setup script
You will be prompted for the name of a schema for the Oracle GoldenGate database objects.
NOTE: The schema must be created prior to running this script.
NOTE: Stop all DDL replication before starting this installation.
Enter Oracle GoldenGate schema name:oggs


Marker setup table script complete, running verification script...
Please enter the name of a schema for the GoldenGate database objects:
Setting schema name to OGGS
MARKER TABLE
-------------------------------
OK
MARKER SEQUENCE
-------------------------------
OK
Script complete.


SQL> @ddl_setup
Oracle GoldenGate DDL Replication setup script
Verifying that current user has privileges to install DDL Replication...
You will be prompted for the name of a schema for the Oracle GoldenGate database objects.
NOTE: For an Oracle 10g source, the system recycle bin must be disabled. For Oracle 11g and later, it can be enabled
NOTE: The schema must be created prior to running this script.
NOTE: Stop all DDL replication before starting this installation.
Enter Oracle GoldenGate schema name:oggs
Working, please wait ...
Spooling to file ddl_setup_spool.txt
Checking for sessions that are holding locks on Oracle Golden Gate metadata tables ...
Check complete.

Using OGGS as a Oracle GoldenGate schema name.
Working, please wait ...
DDL replication setup script complete, running verification script...
Please enter the name of a schema for the GoldenGate database objects:
Setting schema name to OGGS

CLEAR_TRACE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
CREATE_TRACE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
TRACE_PUT_LINE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
INITIAL_SETUP STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
DDLVERSIONSPECIFIC PACKAGE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
DDLREPLICATION PACKAGE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
DDLREPLICATION PACKAGE BODY STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
DDL IGNORE TABLE
-----------------------------------
OK
DDL IGNORE LOG TABLE
-----------------------------------
OK
DDLAUX PACKAGE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
DDLAUX PACKAGE BODY STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
SYS.DDLCTXINFO PACKAGE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
SYS.DDLCTXINFO PACKAGE BODY STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
DDL HISTORY TABLE
-----------------------------------
OK
DDL HISTORY TABLE(1)
-----------------------------------
OK
DDL DUMP TABLES
-----------------------------------
OK
DDL DUMP COLUMNS
-----------------------------------
OK
DDL DUMP LOG GROUPS
-----------------------------------
OK
DDL DUMP PARTITIONS
-----------------------------------
OK
DDL DUMP PRIMARY KEYS
-----------------------------------
OK
DDL SEQUENCE
-----------------------------------
OK
GGS_TEMP_COLS
-----------------------------------
OK
GGS_TEMP_UK
-----------------------------------
OK
DDL TRIGGER CODE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
DDL TRIGGER INSTALL STATUS
-----------------------------------
OK
DDL TRIGGER RUNNING STATUS
------------------------------------------------------------------------------------------------------------------------
ENABLED
STAYMETADATA IN TRIGGER
------------------------------------------------------------------------------------------------------------------------
OFF
DDL TRIGGER SQL TRACING
------------------------------------------------------------------------------------------------------------------------
0
DDL TRIGGER TRACE LEVEL
------------------------------------------------------------------------------------------------------------------------
NONE
LOCATION OF DDL TRACE FILE
------------------------------------------------------------------------------------------------------------------------
/oracle/base/product/19.3/rdbms/log/ggs_ddl_trace.log
Analyzing installation status...

VERSION OF DDL REPLICATION
------------------------------------------------------------------------------------------------------------------------
OGGCORE_19.1.0.0.0_PLATFORMS_191017.1054

STATUS OF DDL REPLICATION
------------------------------------------------------------------------------------------------------------------------
SUCCESSFUL installation of DDL Replication software components

Script complete.

SQL> @role_setup
GGS Role setup script
This script will drop and recreate the role GGS_GGSUSER_ROLE
To use a different role name, quit this script and then edit the params.sql script to change the gg_role parameter to the preferred name. (Do not run the script.)
You will be prompted for the name of a schema for the GoldenGate database objects.
NOTE: The schema must be created prior to running this script.
NOTE: Stop all DDL replication before starting this installation.
Enter GoldenGate schema name:oggs
Wrote file role_setup_set.txt
PL/SQL procedure successfully completed.
Role setup script complete
Grant this role to each user assigned to the Extract, GGSCI, and Manager processes, by using the following SQL command:
GRANT GGS_GGSUSER_ROLE TO <loggedUser>
where <loggedUser> is the user assigned to the GoldenGate processes.


SQL> GRANT GGS_GGSUSER_ROLE TO oggs;
Grant succeeded.

SQL> @ddl_enable
Trigger altered.

SQL> @ddl_status
Please enter the name of a schema for the GoldenGate database objects:
oggs
Setting schema name to OGGS

CLEAR_TRACE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
CREATE_TRACE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
TRACE_PUT_LINE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
INITIAL_SETUP STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
DDLVERSIONSPECIFIC PACKAGE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
DDLREPLICATION PACKAGE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
DDLREPLICATION PACKAGE BODY STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors

DDL IGNORE TABLE
-----------------------------------
OK
DDL IGNORE LOG TABLE
-----------------------------------
OK
DDLAUX PACKAGE STATUS:

Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
DDLAUX PACKAGE BODY STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
SYS.DDLCTXINFO PACKAGE STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
SYS.DDLCTXINFO PACKAGE BODY STATUS:
Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
DDL HISTORY TABLE
-----------------------------------
OK
DDL HISTORY TABLE(1)
-----------------------------------
OK
DDL DUMP TABLES
-----------------------------------
OK
DDL DUMP COLUMNS
-----------------------------------
OK
DDL DUMP LOG GROUPS
-----------------------------------
OK
DDL DUMP PARTITIONS
-----------------------------------
OK
DDL DUMP PRIMARY KEYS
-----------------------------------
OK
DDL SEQUENCE
-----------------------------------
OK
GGS_TEMP_COLS
-----------------------------------
OK
GGS_TEMP_UK
-----------------------------------
OK
DDL TRIGGER CODE STATUS:

Line/pos  Error
---------------------------------------- -----------------------------------------------------------------
No errors  No errors
DDL TRIGGER INSTALL STATUS
-----------------------------------
OK
DDL TRIGGER RUNNING STATUS
------------------------------------------------------------------------------------------------------------------------
ENABLED
STAYMETADATA IN TRIGGER
------------------------------------------------------------------------------------------------------------------------
OFF
DDL TRIGGER SQL TRACING
------------------------------------------------------------------------------------------------------------------------
0
DDL TRIGGER TRACE LEVEL
------------------------------------------------------------------------------------------------------------------------
NONE
LOCATION OF DDL TRACE FILE
------------------------------------------------------------------------------------------------------------------------
/oracle/base/product/19.3/rdbms/log/ggs_ddl_trace.log
Analyzing installation status...
VERSION OF DDL REPLICATION
------------------------------------------------------------------------------------------------------------------------
OGGCORE_19.1.0.0.0_PLATFORMS_191017.1054
STATUS OF DDL REPLICATION
------------------------------------------------------------------------------------------------------------------------
SUCCESSFUL installation of DDL Replication software components

SQL>select object_name from all_objects where object_type='TABLE' and owner='OGGS' ->GGS_* table이 생성

OBJECT_NAME
------------------------------------------------------------------------------------------------------------------------
GGS_DDL_COLUMNS
GGS_DDL_HIST
GGS_DDL_HIST_ALT
GGS_DDL_LOG_GROUPS
GGS_DDL_OBJECTS
GGS_DDL_PARTITIONS
GGS_DDL_PRIMARY_KEYS
GGS_DDL_RULES
GGS_DDL_RULES_LOG
GGS_MARKER
GGS_SETUP
GGS_STICK
GGS_TEMP_COLS
GGS_TEMP_UK
TCUSTMER
TCUSTORD
16 rows selected.

GGSCI (single) 1> edit param ext01

--# DDL
DDL INCLUDE ALL
DDLOPTIONS REPORT

GGSCI (single) 2> add extract ext01, tranlog begin now
EXTRACT added.

GGSCI (single) 3> add exttrail ./dirdat/ea, extract ext01, megabytes 1024
EXTTRAIL added.

GGSCI (single) 4> info all
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
MANAGER     RUNNING                                           
EXTRACT     STOPPED     EXT01       00:00:00      00:00:50    
EXTRACT     RUNNING     PMP01       00:00:00      00:00:00    
REPLICAT    ABENDED     REP01       00:00:00      29:05:35    

GGSCI (single) 5> start ext01
Sending START request to MANAGER ...
EXTRACT EXT01 starting

GGSCI (single) 6> info all
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
MANAGER     RUNNING                                           
EXTRACT     RUNNING     EXT01       00:00:55      00:00:01    
EXTRACT     RUNNING     PMP01       00:00:00      00:00:05    
REPLICAT    ABENDED     REP01       00:00:00      29:05:40    

GGSCI (single) 7> edit param rep01
--# DDL
DDL INCLUDE ALL
DDLOPTIONS REPORT

GGSCI (single) 8> start rep01
Sending START request to MANAGER ...
REPLICAT REP01 starting

 

GGSCI (single) 9> info all
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
MANAGER     RUNNING                                           
EXTRACT     RUNNING     EXT01       00:00:00      00:00:08    
EXTRACT     RUNNING     PMP01       00:00:00      00:00:01    
REPLICAT    RUNNING     REP01       00:00:00      00:00:02    

-- replicat process report 조회

2022-01-13 01:24:28  INFO    OGG-00487  DDL operation included [INCLUDE ALL], optype [CREATE], objtype [TABLE], objowner "OGGT", objname "TCUSTORD".
2022-01-13 01:24:28  INFO    OGG-00484  Executing DDL operation.
2022-01-13 01:24:28  INFO    OGG-00483  DDL operation successful.

728x90

'OGG' 카테고리의 다른 글

[OGG] DDL Deinstall  (0) 2022.01.14
[OGG] OGG-01496 Failed to open target trail file  (0) 2022.01.14
[OGG] Password 암호화  (0) 2022.01.13
[OGG] Process 변경 및 삭제  (0) 2022.01.13
[OGG] Process 연동  (0) 2022.01.13
728x90
-- credentialstore
-- 생성
 
>add credentialstore
>alter credentialstore add user oggs password ogg alias ogg1
 
>edit param exta
>useridalias ogg1
 
>dblogin useridalias ogg1
 
-- 확인 
>info credentialstore
 
-- keygen
$cd ogg_home
$keygen 128 5 
-> 128bit 5개 비번 생성
$cd ogg_home
$vi ENCKEYS
-> 확장자 없어야 됨
-> windows : rename ENCKEYS.txt ENCKEYs
 
key1 0x06698F15FD959774D19FD93622AF2367
key2 0x3AB1AB665009D87A9AE721173C73A846
key3 0x6FF9C737A47C1801622F6A7756372D26
key4 0xA441E408F7EF58072B77B25770FBB105
key5 0xD889005A4A63990DF4BEFA3789BF3665
 
$ggsci
>encrypt password ogg AES128 encryption key1
>dblogin userid oggs, password (encrypted password) AES128 encryption key1
 

 

728x90

'OGG' 카테고리의 다른 글

[OGG] OGG-01496 Failed to open target trail file  (0) 2022.01.14
[OGG] DDL 설정  (2) 2022.01.13
[OGG] Process 변경 및 삭제  (0) 2022.01.13
[OGG] Process 연동  (0) 2022.01.13
[OGG] Checkpointtable  (0) 2022.01.13
728x90
-- process 변경
GGSCI (single) 1> stop ext01
Sending STOP request to EXTRACT EXT01 ...
Request processed.
 
GGSCI (single) 2> alter exttrail ./dirdat/ea, extract ext01, megabytes 50
EXTTRAIL altered.
 
GGSCI (single) 3> start ext01
Sending START request to MANAGER ...
EXTRACT EXT01 starting
alter exttrail <trail 경로>, extract <프로세스명>, megabytes <trail file size>
 
-- process 삭제 - classic mode
GGSCI (single) 1> stop ext01
Sending STOP request to EXTRACT EXT01 ...
Request processed.

GGSCI (single) 2> dblogin userid oggs/ogg
Successfully logged into database.

GGSCI (single as oggt@orcl) 3> delete extract ext01
Deleted EXTRACT EXT01.
 

 

728x90

'OGG' 카테고리의 다른 글

[OGG] DDL 설정  (2) 2022.01.13
[OGG] Password 암호화  (0) 2022.01.13
[OGG] Process 연동  (0) 2022.01.13
[OGG] Checkpointtable  (0) 2022.01.13
[OGG] INSTALL _ Redhat  (0) 2022.01.13
728x90
-- Manager process 
$ggsci
GGSCI (single) 1> edit param mgr
PORT 9020
DYNAMICPORTLIST 9011-9019
PURGEOLDEXTRACTS ./dirdat/ea*, MINKEEPFILES 20
LAGCRITICALSECONDS 60 
LAGREPORTMINUTES 5 
LAGINFOMINUTE 5 
GGSCI (single) 2> start mgr
Manager started.
GGSCI (single) 3> info all
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
MANAGER     RUNNING                                           
EXTRACT     STOPPED     EXT01       00:00:00      00:04:08    
 
-- Extract process

GGSCI (single) 1> edit param ext01

extract ext01
userid oggs, password ogg
exttrail ./dirdat/ea
reportrollover at 00:00
reportcount every 1000, records
table oggs.*;
 
GGSCI (single) 2> add extract ext01, tranlog begin now
EXTRACT added.
 
GGSCI (single) 3> add exttrail ./dirdat/ea, extract ext01
EXTTRAIL added.
 
GGSCI (single) 4> start ext01
 
Sending START request to MANAGER ...
EXTRACT EXT01 starting
 
GGSCI (single) 5> info all
 
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
MANAGER     RUNNING                                           
EXTRACT     RUNNING     EXT01       00:05:24      00:00:00  
 

-- Data insert

$sqlplus oggs/ogg
 
SQL> @demo_ora_insert
 
1 row created.
1 row created.
1 row created.
1 row created.
Commit complete.
 
SQL> disconn
Disconnected from Oracle Database 19c Standard Edition 2 Release 19.0.0.0.0 - Production
Version 19.13.0.0.0
 
SQL> conn oggt
Enter password: 
Connected.
 
SQL> @demo_ora_insert
 
1 row created.
1 row created.
1 row created.
1 row created.
Commit complete.
 
-- Pump process

GGSCI (single) 1> edit param pmp01

extract pmp01
rmthost localhost, mgrport 7840
passthru
rmttrail ./dirdat/ra
table oggs.*;

GGSCI (single) 2> add extract pmp01, exttrailsource ./dirdat/ea

EXTRACT added.
 
GGSCI (single) 3> add rmttrail ./dirdat/ra, extract pmp01
RMTTRAIL added.
 
GGSCI (single) 4> start pmp01
 
Sending START request to MANAGER ...
EXTRACT PMP01 starting
 
GGSCI (single) 5> info all
 
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
 
MANAGER     RUNNING                                           
EXTRACT     RUNNING     EXT01       00:00:00      00:00:06    
EXTRACT     RUNNING     PMP01       00:00:00      00:00:02    
 
-- Replicat process
GGSCI (single) 1> edit param rep01
replicat rep01
userid oggt, password ogg
map oggs.*, target oggt.*;
GGSCI (single) 2> add replicat rep01, exttrail ./dirdat/ra, nodbcheckpoint
REPLICAT added.
 
GGSCI (single) 3> start rep01
Sending START request to MANAGER ...
REPLICAT REP01 starting
 
GGSCI (single) 4> info all
Program     Status      Group       Lag at Chkpt  Time Since Chkpt
 
MANAGER     RUNNING                                           
EXTRACT     RUNNING     EXT01       00:00:00      00:00:08    
EXTRACT     RUNNING     PMP01       00:00:00      00:00:09    
REPLICAT    RUNNING     REP01       00:00:00      00:00:07  
 
728x90

'OGG' 카테고리의 다른 글

[OGG] DDL 설정  (2) 2022.01.13
[OGG] Password 암호화  (0) 2022.01.13
[OGG] Process 변경 및 삭제  (0) 2022.01.13
[OGG] Checkpointtable  (0) 2022.01.13
[OGG] INSTALL _ Redhat  (0) 2022.01.13
728x90
* integrated mode 사용 X
* target schema에 생성
* 1개의 checkpointtable만 됨, 여러 replicat process는 1개의 checkpointtable로 관리
 
GGSCI> edit param ./GLOBALS 
CHECKPOINTTABLE OGG.GGSCHKPT 
 
GGSCI (single) 2> dblogin userid oggt
Password: 
Successfully logged into database.
 
GGSCI (single as oggt@orcl) 3> add checkpointtable oggt.ggschkpt -> target에 생성
Successfully created checkpoint table oggt.ggschkpt.
 
GGSCI (single as oggt@orcl) 4>add replicat repa exttrail ./dirdat/ra, checkpointtable oggt.ggschkpt
 
-- checkpointtable 사용하지 않을 경우
 
GGSCI> add replicat repa, exttrail ./dirdat/ra, nodbcheckpoint
 
-- checkpointtable 확인
$ggsci
>dblogin userid oggt
>info checkpointtable

 

728x90

'OGG' 카테고리의 다른 글

[OGG] DDL 설정  (2) 2022.01.13
[OGG] Password 암호화  (0) 2022.01.13
[OGG] Process 변경 및 삭제  (0) 2022.01.13
[OGG] Process 연동  (0) 2022.01.13
[OGG] INSTALL _ Redhat  (0) 2022.01.13
728x90
- OS 사전환경 조성 
1. OS user 생성(oracle 계정의 그룹과 동일 설정)
# id oracle
uid=1001(oracle) gid=1001(dba) groups=1001(dba)
# useradd -g dba ogg
# passwd ogg
Changing password for user ogg.
New password: 
BAD PASSWORD: The password is shorter than 8 characters
Retype new password: 
passwd: all authentication tokens updated successfully.
 
2. OGG_HOME directory 생성
# mkdir /ogg
# chown -R ogg:dba /ogg/
 
3. OGG 계정 profile 설정 
$cat .bash_profile 
# .bash_profile
 
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
 
# User specific environment and startup programs
export PATH
umask 022
export EDITOR=vi
export PS1="[\u@\h-$ORACLE_SID:\w]$"
export ORACLE_BASE=/oracle/base
export ORACLE_HOME=$ORACLE_BASE/product/19.3
export ORACLE_SID=orcl
export NLS_LANG=AMERICAN_AMERICA.AL32UTF8
export TNS_ADMIN=$ORACLE_HOME/network/admin
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib:/usr/local/lib:.:
export PATH=$ORACLE_HOME/bin:$ORACLE_HOME/OPatch:.:$PATH:$OGG_HOME
export ORACLE_TERM=xterm
stty erase ^H
export OGG_HOME=/ogg/oggs
 
- DB 사전 환경 확인 
1. archive log list
SQL> archive log list;
Database log mode        Archive Mode
Automatic archival        Enabled
Archive destination        /oracle/base/product/19.3/dbs/arch
Oldest online log sequence     16
Next log sequence to archive   18
Current log sequence        18
 
2. enable_goldengate_replication parameter 
SQL>  show parameter goldengate
 
NAME      TYPE  VALUE
------------------------------------ ----------- ------------------------------
enable_goldengate_replication      boolean  TRUE
resource_manage_goldengate      boolean  FALSE

 

3. supplemental log
SQL> select supplemental_log_data_min from v$database;
 
SUPPLEME
--------
YES

 

- OGG 설치
 
$unzip V983658-01.zip -d /ogg
$mkdir oraInventory
$vi oraInst.loc
inventory_loc=/ogg/oraInventory
inst_group=dba
 
$./runInstaller -silent -invPtrLoc /ogg/oraInst.loc \
INSTALL_OPTION=ORA19c \
SOFTWARE_LOCATION=/ogg/oggs
 
============================================================================
- rsp 파일 사용 설치 
$cd /ogg/fbo_ggs_Linux_x64_shiphome/Disk1/response
$vi oggcore.rsp
INSTALL_OPTION=ORA12c
SOFTWARE_LOCATION=/ogg/oggs

 

$./runInstaller -responseFile /ogg/fbo_ggs_Linux_x64_shiphome/Disk1/response/oggcore.rsp -invPtrLoc /ogg/oraInst.loc -silent
 
============================================================================
$ggsci
Oracle GoldenGate Command Interpreter for Oracle
Version 19.1.0.0.4 OGGCORE_19.1.0.0.0_PLATFORMS_191017.1054_FBO
Linux, x64, 64bit (optimized), Oracle 19c on Oct 17 2019 21:16:29
Operating system character set identified as UTF-8.
 
Copyright (C) 1995, 2019, Oracle and/or its affiliates. All rights reserved.
 

GGSCI (rhel8.3single) 1> 
**
ggsci: error while loading shared libraries: libnnz12.so: cannot open shared object file: No such file or directory
-> INSTALL_OPTION
-> bash_profile : export PATH=$OGG_HOME
 

확인!cle19 install

 

728x90

'OGG' 카테고리의 다른 글

[OGG] DDL 설정  (2) 2022.01.13
[OGG] Password 암호화  (0) 2022.01.13
[OGG] Process 변경 및 삭제  (0) 2022.01.13
[OGG] Process 연동  (0) 2022.01.13
[OGG] Checkpointtable  (0) 2022.01.13

+ Recent posts