note:适用于11g之间的同步配置
一、数据库配置
1.1 开启归档
startup mount
alter database archivelog;
note:作为目标端,不capture数据不需要配置
1.2 开启强制日志
alter database force logging;
note:作为目标端,不capture数据不需要配置
1.3 开启数据库最小附加日志
alter database add supplemental log data;
note:作为目标端,不capture数据不需要配置
1.4 配置参数
alter system set enable_goldengate_replication=true;
note:11.2.0.4以上需要配置
1.5 创建OGG用户和表空间
表空间
create tablespace ggtbs datafile '+DATA' size 1g autoextend on;
用户
create user ggadmin identified by ggadmin default tablespace ggtbs quota unlimited on ggtbs;
授权
grant connect,resource to ggadmin;
grant alter session to ggadmin;
grant select any dictionary to ggadmin;
grant select any transaction to ggadmin;
grant select any table to ggadmin;
grant flashback any table to ggadmin;
grant alter any table to ggadmin;
exec dbms_goldengate_auth.grant_admin_privilege('GGADMIN','*',TRUE)
note:除了必要权限,其他权限可以根据实际情况而定。
二、OGG安装
2.1 创建用户和目录
组
group