11g rac 添加一个控制文件
2017-06-28 11:35
393 查看
一、环境11g rac
二、演示步骤1. 查看控制文件路径SYS@ysdb1>show parameter control_files
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
control_files string +DATA1/ysdb/control01.ctl
2. 关闭所有实例,启动一个实例到nomount状态,恢复一个控制文件[oracle@ysdb1 dbs]$ rman target /
Recovery Manager: Release 11.2.0.4.0 - Production on Wed Jun 28 11:10:03 2017
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
connected to target database: YSDB (DBID=3762312883)
RMAN> shutdown immediate;
using target database control file instead of recovery catalog
database closed
database dismounted
Oracle instance shut down
RMAN>
RMAN>
RMAN> startup nomount;
connected to target database (not started)
Oracle instance started
Total System Global Area 647204864 bytes
Fixed Size 2256032 bytes
Variable Size 536871776 bytes
Database Buffers 104857600 bytes
Redo Buffers 3219456 bytes
RMAN> restore controlfile to '+data1/ysdb/control03.ctl' from '+data1/ysdb/control01.ctl';
Starting restore at 28-JUN-17
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=34 instance=ysdb1 device type=DISK
channel ORA_DISK_1: copied control file copy
Finished restore at 28-JUN-17
RMAN>
3. 在nomount下,修改参数文件,重启数据库 [oracle@ysdb1 dbs]$ sqlplus / as sysdbaSQL*Plus: Release 11.2.0.4.0 Production on Wed Jun 28 11:14:08 2017Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to:Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit ProductionWith the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,Data Mining and Real Application Testing options SYS@ysdb1>select status from v$instance; STATUS------------STARTED SYS@ysdb1>alter system set control_files='+data1/ysdb/control01.ctl','+data1/ysdb/control03.ctl' scope=spfile sid='*'; System altered. SYS@ysdb1>shutdown immediate;ORA-01507: database not mountedORACLE instance shut down. SYS@ysdb1>startupORACLE instance started. Total System Global Area 647204864 bytesFixed Size 2256032 bytesVariable Size 536871776 bytesDatabase Buffers 104857600 bytesRedo Buffers 3219456 bytesDatabase mounted.Database opened.SYS@ysdb1>show parameter control_files NAME TYPE VALUE------------------------------------ ----------- ------------------------------control_files string +DATA1/ysdb/control01.ctl, +DA TA1/ysdb/control03.ctlSYS@ysdb1>
二、演示步骤1. 查看控制文件路径SYS@ysdb1>show parameter control_files
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
control_files string +DATA1/ysdb/control01.ctl
2. 关闭所有实例,启动一个实例到nomount状态,恢复一个控制文件[oracle@ysdb1 dbs]$ rman target /
Recovery Manager: Release 11.2.0.4.0 - Production on Wed Jun 28 11:10:03 2017
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
connected to target database: YSDB (DBID=3762312883)
RMAN> shutdown immediate;
using target database control file instead of recovery catalog
database closed
database dismounted
Oracle instance shut down
RMAN>
RMAN>
RMAN> startup nomount;
connected to target database (not started)
Oracle instance started
Total System Global Area 647204864 bytes
Fixed Size 2256032 bytes
Variable Size 536871776 bytes
Database Buffers 104857600 bytes
Redo Buffers 3219456 bytes
RMAN> restore controlfile to '+data1/ysdb/control03.ctl' from '+data1/ysdb/control01.ctl';
Starting restore at 28-JUN-17
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=34 instance=ysdb1 device type=DISK
channel ORA_DISK_1: copied control file copy
Finished restore at 28-JUN-17
RMAN>
3. 在nomount下,修改参数文件,重启数据库 [oracle@ysdb1 dbs]$ sqlplus / as sysdbaSQL*Plus: Release 11.2.0.4.0 Production on Wed Jun 28 11:14:08 2017Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to:Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit ProductionWith the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,Data Mining and Real Application Testing options SYS@ysdb1>select status from v$instance; STATUS------------STARTED SYS@ysdb1>alter system set control_files='+data1/ysdb/control01.ctl','+data1/ysdb/control03.ctl' scope=spfile sid='*'; System altered. SYS@ysdb1>shutdown immediate;ORA-01507: database not mountedORACLE instance shut down. SYS@ysdb1>startupORACLE instance started. Total System Global Area 647204864 bytesFixed Size 2256032 bytesVariable Size 536871776 bytesDatabase Buffers 104857600 bytesRedo Buffers 3219456 bytesDatabase mounted.Database opened.SYS@ysdb1>show parameter control_files NAME TYPE VALUE------------------------------------ ----------- ------------------------------control_files string +DATA1/ysdb/control01.ctl, +DA TA1/ysdb/control03.ctlSYS@ysdb1>
相关文章推荐
- ORACLE 11g在ASM磁盘组上添加控制文件
- Oracle 11g RAC RMAN ORA-00245 control file backup operation failed 错误 与 控制文件备份 说明
- oracle 11g 添加控制文件
- oracle 10g rac 添加控制文件
- oracle之 RAC 11G ASM下控制文件多路复用
- ORACLE 11gR2 RAC添加控制文件
- Oracle 11g RAC RMAN ORA-00245 control file backup operation failed 错误 与 控制文件备份 说明
- rac 中添加控制文件冗余
- 『ORACLE』RAC—控制文件多路径复制(11g)
- oracle之 RAC 11G ASM下控制文件多路复用
- Oracle 11g RAC RMAN ORA-00245 control file backup operation failed 错误 与 控制文件备份 说明
- Oracle 添加冗余控制文件 for RAC On Linux
- rac环境下面添加控制文件
- Oracle 11g在ASM磁盘组上添加控制文件
- Oracle 11g RAC RMAN ORA-00245 control file backup operation failed 错误 与 控制文件备份 说明
- 一个站点控制另一个站点的文件(添加,删除)用Webservices
- 备份控制文件之后,添加数据文件,数据文件无备份丢失后的恢复
- RAC环境中的快照控制文件
- hashtab:为文件属性添加一个数字指纹
- 恢复缺少一个控制文件