PROTECTION_MODE is UNPROTECTED at standby database分析
PROTECTION_MODE is UNPROTECTED at standby database分析
数据库版本
SQL> select * from v$version; BANNER -------------------------------------------------------------------------------------------------------------------------------- Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bi PL/SQL Release 10.2.0.1.0 - Production CORE 10.2.0.1.0 Production TNS for Linux: Version 10.2.0.1.0 - Production NLSRTL Version 10.2.0.1.0 – Production
1、问题描述(data guard采用最大性能模式,但是备库的PROTECTION_MODE 竟是UNPROTECTED?)
主库 SQL> select DATABASE_ROLE,OPEN_MODE,PROTECTION_MODE from v$database; DATABASE_ROLE OPEN_MODE PROTECTION_MODE -------------------------------- -------------------- ---------------------------------------- PRIMARY READ WRITE MAXIMUM PERFORMANCE 备库 SQL> select DATABASE_ROLE,OPEN_MODE,PROTECTION_MODE from v$database; DATABASE_ROLE OPEN_MODE PROTECTION_MODE -------------------------------- -------------------- ---------------------------------------- PHYSICAL STANDBY MOUNTED UNPROTECTED
2、问题补充描述
备库日志正常应用,主库做DML操作,备库read only开启也可以看到DML的结果。说明此data guard本身是没有问题的。但是为什么备库的PROTECTION_MODE 会出现 UNPROTECTED呢?万分不解,在朋友的帮助下找到了关于这个问题的描述如下:
maximize_standby_db_clause
Use this clause to specify the level of protection for the data in your database environment. You specify this clause from the primary database, which must be mounted but not open.
Note:
The PROTECTED and UNPROTECTED keywords have been replaced for clarity but are still supported. PROTECTED is equivalent to TO MAXIMIZE PROTECTION. UNPROTECTED is equivalent to TO MAXIMIZE PERFORMANCE.
3、问题分析
根据官档的解释:
PROTECTED= TO MAXIMIZE PROTECTION UNPROTECTED= TO MAXIMIZE PERFORMANCE
这样就不难看出了,我们data guard中PROTECTION_MODE =UNPROTECTED ,这根本就没有任何问题,只不过是想当于MAXIMIZE PERFORMANCE的另一种叫法是 UNPROTECTED而已。
4、总结:
PROTECTED= TO MAXIMIZE PROTECTION UNPROTECTED= TO MAXIMIZE PERFORMANCE
一些关键性参数的理解问题。