2、启用ogg的ddl复制
2.1 创建相应的用户以及表空间
sqlplus / as sysdba
create tablespace ogg datafile '/soft/TEST/ogg01.dbf' size 10M;
create user ogg identified by oracle default tablespace ogg;
赋权
GRANT CREATE TABLE,CREATE SEQUENCE TO OGG; -----必须
GRANT EXECUTE ON UTL_FILE TO ogg
GRANT CONNECT TO ogg;
GRANT CREATE SESSION TO ogg;
GRANT ALTER SESSION TO ogg;
GRANT RESOURCE TO ogg;
GRANT SELECT ANY DICTIONARY TO ogg;
GRANT SELECT ANY TABLE TO ogg;
GRANT FLASHBACK ANY TABLE TO ogg;
GRANT ALTER ANY TABLE TO ogg;
grant create table to ogg;
grant dba to ogg;
2.3 以sysdba角色运行相应脚本
@marker_setup.sql
alter system set RECYCLEBIN=off; --运行ddl_setup前必须保证关闭数据库的回收站特性
@ddl_setup.sql
@role_setup.sql
GRANT GGS_GGSUSER_ROLE to ogg;
@ddl_enable.sql
关闭
@ddl_disable.sql
查看状态
@ddl_status.sql
验证脚本安装
@marker_status
NOTE:在源端ogg的ddl支持是默认关闭的,如果需要启用的话需在extract进程的参数文件中加入ddl参数;
在目标端ogg的ddl支持是默认开启的,如果有其他需求可以在replicat进程的参数文件中使用ddl参数来
过滤或或者忽略某些ddl操作。