OMF添加控制文件_OCP学习笔记(3)
2010-06-24 15:41
323 查看
DBCA选择OMF管理方式,但没有添加多路复用。即
SQL> show parameter db_create
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
db_create_file_dest string d:\oracle\product\10.2.0\orada
ta
db_create_online_log_dest_1 string
db_create_online_log_dest_2 string
db_create_online_log_dest_3 string
db_create_online_log_dest_4 string
db_create_online_log_dest_5 string
只有db_create_file_dest有值,那么ORACLE会在db_create_file_dest目录创建一份(only one)控制文件:
SQL> select name from v$controlfile
2 /
NAME
------------------------------------------------------------------------
D:\ORACLE\PRODUCT\10.2.0\ORADATA\STUDY\CONTROLFILE\O1_MF_625GL8JB_.CTL
Oracle一般建议生成三份控制文件. 下面我们添加控制文件目录:
SQL> alter system set db_create_online_log_dest_1='d:\oracle\product\10.2.0\logs'
SQL> alter system set db_create_online_log_dest_2='d:\oracle\product\10.2.0\logs2'
SQL> alter system set db_create_online_log_dest_3='d:\oracle\product\10.2.0\logs3'
以上添加三个复用目录.
然后生成控制文件脚本:
SQL> alter database backup controlfile to trace;
再就是把control_files参数去除。本来想用reset清掉control_files。很不巧总报错。
只能用生PFILE文件,手工更改的方式:
SQL> create pfile='C:\anran.ora' from spfile.
打开anran.ora,remove control_files参数行。
SQL> STARTUP NOMOUNT pfile='C:\anran.ora'
剩下就是按trace文件脚本重建控制文件就可以了,这里有一点,TRACE文件里有两处脚本,noresetlogs/resetlog.我们最好选用前者。
SQL> show parameter db_create
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
db_create_file_dest string d:\oracle\product\10.2.0\orada
ta
db_create_online_log_dest_1 string
db_create_online_log_dest_2 string
db_create_online_log_dest_3 string
db_create_online_log_dest_4 string
db_create_online_log_dest_5 string
只有db_create_file_dest有值,那么ORACLE会在db_create_file_dest目录创建一份(only one)控制文件:
SQL> select name from v$controlfile
2 /
NAME
------------------------------------------------------------------------
D:\ORACLE\PRODUCT\10.2.0\ORADATA\STUDY\CONTROLFILE\O1_MF_625GL8JB_.CTL
Oracle一般建议生成三份控制文件. 下面我们添加控制文件目录:
SQL> alter system set db_create_online_log_dest_1='d:\oracle\product\10.2.0\logs'
SQL> alter system set db_create_online_log_dest_2='d:\oracle\product\10.2.0\logs2'
SQL> alter system set db_create_online_log_dest_3='d:\oracle\product\10.2.0\logs3'
以上添加三个复用目录.
然后生成控制文件脚本:
SQL> alter database backup controlfile to trace;
再就是把control_files参数去除。本来想用reset清掉control_files。很不巧总报错。
只能用生PFILE文件,手工更改的方式:
SQL> create pfile='C:\anran.ora' from spfile.
打开anran.ora,remove control_files参数行。
SQL> STARTUP NOMOUNT pfile='C:\anran.ora'
剩下就是按trace文件脚本重建控制文件就可以了,这里有一点,TRACE文件里有两处脚本,noresetlogs/resetlog.我们最好选用前者。
相关文章推荐
- OMF添加在线日志_OCP学习笔记(4)
- DBA学习笔记 - chapter 4 数据字典和控制文件(2)
- 井位坐标添加到Las文件功能——Tkinter界面开发学习笔记一
- 学习笔记(二) oracle 的控制文件 control file
- 【python学习笔记】4:精度控制/文件读/split()方法
- LINUX系统学习笔记管道符和作业控制 ,shell变量 , 环境变量配置文件
- 【Github学习笔记】安装git,创建库,添加远程仓库,添加删除文件
- Git学习笔记一--创建版本库、添加文件、提交文件等
- Git 学习笔记(简介、安装、添加提交文件、查看状态及更改信息)
- linux学习笔记(一 文件权限控制)
- Git学习笔记(1)——安装,配置,创建库,文件添加到库
- iOS学习笔记-workspace添加工程时只有一个proj文件问题
- UNIX环境编程学习笔记(7)——文件I/O之文件访问权限与进程访问控制
- Git学习笔记一--创建版本库、添加文件、提交文件等
- Git版本控制管理学习笔记4-文件管理和索引
- 【Git学习笔记】对已经添加到仓库的文件修改后再次提交到仓库
- 【Qt学习笔记】.添加资源文件
- android如何修改dex文件添加非法指令 9efa (学习笔记)
- Pro Oracle Database 11g Administration 学习笔记之第五章(管理控制文件和联机日志文件)
- ALSA声卡12_从零编写之添加音量控制_学习笔记