Data Guard部署物理备库的8大注意事项
Data Guard部署物理备库的8大注意事项
这8点主要是面向 10g R2 以后的 DG 部署
www.zzzyk.com
① 主库设置为force logging模式
[sql]
idle> select force_logging from v$database;
idle> alter database force logging;
② 主库设置为归档模式 www.zzzyk.com
[sql]
idle> archive log list;
idle> shutdown immediate;
idle> startup mount;
idle> alter database archivelog;
idle> archive log list;
③ 配置Standby Redo Log
配置 standby redo log
④ 创建密匙文件(如果不存在的话)
先看文档的解释:
[plain]
You must have SYSDBA system privileges for the user accounts that you use to manage the primary and standby database instances
Furthermore, the SYS user must have the same password on all databases in the configuration.
那么如果password不一样会怎样?
案例如下:
[plain]
Error 1031 received logging on to the standby
Errors in file /u01/app/oracle/diag/rdbms/pri/orcl/trace/orcl_arcf_5769.trc:
ORA-01031: insufficient privileges
PING[ARCf]: Heartbeat failed to connect to standby 'std'. Error is 1031.
显然、抛出 ORA-01031: insufficient privileges
使用 DBCA 建库会在 $ORACLE_HOME/dbs 下自动创建密匙文件
如若没有、可使用 orapwd 命令行工具、其 file 和 password 为必填参数、
例如(假设当前目录是 $ORACLE_HOME/dbs ):
orapwd file=orapworcl password=oracle entries=30 (Linux/Unix 平台命名规则:orapw[sid])
⑤ 设置初始化参数
DG 初始化参数列表
⑥ 数据库的版本要一致
官方文档提到:
[plain]
You must install the same release of Oracle Database Enterprise Edition for the primary database and all standby databases in your Data Guard configuration
⑦ 独立的控制文件
摘自官网:
The primary database and each standby database must have their own control files.
⑧ 统一的存储或文件管理