在10gR2中,oracle簡化了stream的配置的全過程,在9iR2及10gR1中,需要針對stream的捕獲、傳播、應用進程進行配置的步驟
已經被dbms_streams_adm新提供的過程(pre_instantiation_setup/post_instantiation_setup)給封裝起來啦,
配置stream只需要調用兩個存儲過程就可以搞定啦,真是太激動人心啦,下面簡單地介紹一下
dbms_streams_adm的新過程的用法。
1.在stream進行配置前,需要做些準備工作
a 源庫與目標庫初始化參數的設置
alter system set aq_tm_processes=4 scope=spfile;
alter system set job_queue_processes=5 scope=spfile;
alter system set global_names=true scope=spfile;
alter system set streams_pool_size=51m scope=spfile;
說明streams_pool_size在生產環境中最好>200m
b 源庫與目標庫tnsnames.ora配置
確保正確,可用tnsping通
c 源庫與目標庫復制管理員的創建
create user strmadmin identified by strmadminpw
default tablespace &tbs_name quota unlimited on &tbs_name;
grant connect, resource, dba to strmadmin;
d 源庫與目標庫創建互連的數據鏈
connect strmadmin/strmadminpw@test96;
create database link test99.net connect to strmadmin
identified by strmadminpw using 'test99';
connect strmadmin/strmadminpw@test99;
create database link test96.net connect to strmadmin
identified by strmadminpw using 'test96';
說明:必須確保雙方的數據庫鏈是可以連通.
用pre_instantiation_setup/post_instantiation_setup過程時
db link必須用db_name.domain的格式
e 源庫與目標庫必須處于歸檔模式
shutdown immediate;
startup mount;
alter database archivelog;
alter database open;
2.執行pre_instantiation_setup過程
文章來源于領測軟件測試網 http://www.kjueaiud.com/