创建控制文件副本出现错误ORA-00205: error in identifying control file

测试环境:OEL6.5+Oracle 11g R2

    
在做多路复用控制文件的实验时,创建控制文件总是会报错误:ORA-00205: error in identifying control file, check alert log for more info
下面是当时的操作过程:

点击(此处)折叠或打开

  1. SYS@ORCL> show parameter control_files;

  2. NAME                 TYPE     VALUE
  3. ------------------------------------ ----------- ------------------------------
  4. control_files             string     /u01/app/oracle/oradata/ORCL/c
  5.                          ontrol01.ctl, /u01/app/oracle/
  6.                          fast_recovery_area/ORCL/contro
  7.                          l02.ctl
  8. SYS@ORCL> shutdown immediate;
  9. Database closed.
  10. Database dismounted.
  11. ORACLE instance shut down.
  12. SYS@ORCL> ! cp /u01/app/oracle/oradata/ORCL/control01.ctl /home/oracle/control03.ctl

  13. SYS@ORCL> startup nomount;
  14. ORACLE instance started.

  15. Total System Global Area 1653518336 bytes
  16. Fixed Size         2253784 bytes
  17. Variable Size         1006636072 bytes
  18. Database Buffers     637534208 bytes
  19. Redo Buffers         7094272 bytes
  20. SYS@ORCL> alter system set control_files='/u01/app/oracle/oradata/ORCL/control01.ctl,/u01/app/oracle/fast_recovery_area/ORCL/control02.ctl /home/oracle/control03.ctl' scope=spfile;

  21. System altered.

  22. SYS@ORCL> startup force;
  23. ORACLE instance started.

  24. Total System Global Area 1653518336 bytes
  25. Fixed Size         2253784 bytes
  26. Variable Size         1006636072 bytes
  27. Database Buffers     637534208 bytes
  28. Redo Buffers         7094272 bytes
  29. ORA-00205: error in identifying control file, check alert log for more info

    看上去似乎没有错误,于是开始查看alert日志,在日志中看到的 内容如下:

点击(此处)折叠或打开

  1. Mon Feb 01 23:44:54 2016
  2. ALTER DATABASE MOUNT
  3. ORA-00210: cannot open the specified control file
  4. ORA-00202: control file: '/u01/app/oracle/oradata/ORCL/control01.ctl,/u01/app/oracle/fast_recovery_area/ORCL/control02.ctl /home/oracle/control03.ctl'
  5. ORA-27037: unable to obtain file status
  6. Linux-x86_64 Error: 2: No such file or directory
  7. Additional information: 3
  8. ORA-205 signalled during: ALTER DATABASE MOUNT...
    根据提示来看是说文件或路径不存在,而且是在数据库从nomount阶段启动到mount阶段的过程中遇到了文件或路径不存在的错误,而从nomount转换到mount阶段,是实例根据参数文件中的control_files来定位控制文件的,这样一来可以定位错误就在下面的语句当中:

点击(此处)折叠或打开

  1. SYS@ORCL> alter system set control_files='/u01/app/oracle/oradata/ORCL/control01.ctl,/u01/app/oracle/fast_recovery_area/ORCL/control02.ctl /home/oracle/control03.ctl' scope=spfile;

    可是上面明明提示这据SQL更改成功了,为什么会出错呢?思来想去可能问题出在后面的参数值的格式上,于是将这句SQL改为:

点击(此处)折叠或打开

  1. SYS@ORCL> alter system set control_files='/u01/app/oracle/oradata/ORCL/control01.ctl','/u01/app/oracle/fast_recovery_area/ORCL/control02.ctl','/home/oracle/control03.ctl' scope=spfile;

  2. System altered.

  3. SYS@ORCL> startup force;
  4. ORACLE instance started.

  5. Total System Global Area 1653518336 bytes
  6. Fixed Size         2253784 bytes
  7. Variable Size         1006636072 bytes
  8. Database Buffers     637534208 bytes
  9. Redo Buffers         7094272 bytes
  10. Database mounted.
  11. Database opened.
  12. SYS@ORCL> show parameter control_files;

  13. NAME                 TYPE     VALUE
  14. ------------------------------------ ----------- ------------------------------
  15. control_files             string     /u01/app/oracle/oradata/ORCL/c
  16.                          ontrol01.ctl, /u01/app/oracle/
  17.                          fast_recovery_area/ORCL/contro
  18.                          l02.ctl, /home/oracle/control0
  19.                          3.ctl
    果然是格式的问题,那么将单引号改为双引号会怎样?

点击(此处)折叠或打开

  1. SYS@ORCL> alter system set control_files="/u01/app/oracle/oradata/ORCL/control01.ctl","/u01/app/oracle/fast_recovery_area/ORCL/control02.ctl","/home/oracle/control03.ctl" scope=spfile;

  2. System altered.

  3. SYS@ORCL> startup force;
  4. ORACLE instance started.

  5. Total System Global Area 1653518336 bytes
  6. Fixed Size         2253784 bytes
  7. Variable Size         1006636072 bytes
  8. Database Buffers     637534208 bytes
  9. Redo Buffers         7094272 bytes
  10. Database mounted.
  11. Database opened.
  12. SYS@ORCL> show parameter control_files;

  13. NAME                 TYPE     VALUE
  14. ------------------------------------ ----------- ------------------------------
  15. control_files             string     /u01/app/oracle/oradata/ORCL/c
  16.                          ontrol01.ctl, /u01/app/oracle/
  17.                          fast_recovery_area/ORCL/contro
  18.                          l02.ctl, /home/oracle/control0
  19.                          3.ctl

    也能成功,在此处的control_files参数是单引号和双引号之间没有区别。那么把失败的情况换成双引号结果会怎样?

点击(此处)折叠或打开

  1. SYS@ORCL> alter system set control_files="/u01/app/oracle/oradata/ORCL/control01.ctl,/u01/app/oracle/fast_recovery_area/ORCL/control02.ctl /home/oracle/control03.ctl" scope=spfile;

  2. System altered.

  3. SYS@ORCL> startup force;
  4. ORACLE instance started.

  5. Total System Global Area 1653518336 bytes
  6. Fixed Size         2253784 bytes
  7. Variable Size         1006636072 bytes
  8. Database Buffers     637534208 bytes
  9. Redo Buffers         7094272 bytes
  10. ORA-00205: error in identifying control file, check alert log for more info

    同样还是失败, 也就是说,在修改此参数时,一个单/双 引号里的内容均会被认为是一个完整的路径,要想指定多个路径,必须以单/双引号分别指定路径,路径之间以逗号隔开,当然,全部是西文字符。


来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/29067253/viewspace-1985416/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/29067253/viewspace-1985416/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值