ITPub博客

首页 > Linux操作系统 > Linux操作系统 > 10g Stream 单表同步问题

10g Stream 单表同步问题

原创 Linux操作系统 作者:tolywang 时间:2010-03-28 06:59:05 0 删除 编辑
主库数据库名:  mxb2b
从库数据库名:  b2beai  

1. 在主库和从库配置初始化参数 。
b2b-test-ap2<*mxb2b*/home/oracle>$sqlplus "/as sysdba"
SQL> alter system set aq_tm_processes=2 scope=both;
SQL> alter system set global_names=true scope=both;
job_queue_processes= 10
parallel_max_servers = 320
SQL> alter system set undo_retention=3600 scope=both;
SQL> alter system set nls_date_format='YYYY-MM-DD HH24:MI:SS' scope=spfile;
SQL> alter system set streams_pool_size=500M scope=spfile;
SQL> alter system set utl_file_dir='*' scope=spfile;
open_links = 4  
最后重新启动主库和从库 。



2. 保证两个数据库处于自动归档模式 。



3. 创建 stream 管理用户 。

3.1  创建主库环境stream管理用户 。

在主库上以 sysdba 身份登入, 创建stream专用的表空间。
$sqlplus / as sysdba
SQL> create tablespace tbs_stream datafile '/data1/mxb2b/tbs_stream01.dbf' size 500m
     autoextend on maxsize unlimited segment space management auto ;   
  
转移logmnr的表空间  
SQL> execute dbms_logmnr_d.set_tablespace('tbs_stream') ;  

创建stream用户  
create user strmadmin identified by strmadmin
default tablespace tbs_stream temporary tablespace temp ;

授予权限  
SQL> grant connect,resource , dba, aq_administrator_role to strmadmin ;
begin
dbms_streams_auth.grant_admin_privilege(
grantee=>'strmadmin',
grant_privileges=>true);
end;
/

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/35489/viewspace-630552/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论
Oracle , MySQL, SAP IQ, SAP HANA, PostgreSQL, Tableau 技术讨论,希望在这里一起分享知识,讨论技术,畅谈人生 。

注册时间:2007-12-10

  • 博文量
    5595
  • 访问量
    14695689