码迷,mamicode.com
首页 > 其他好文 > 详细

测试库重启出来的问题

时间:2017-03-28 15:28:25      阅读:168      评论:0      收藏:0      [点我收藏+]

标签:导致   dia   hive   测试   buffers   instance   font   归档   arch   

今天重启一套测试库,先shutdown immediate报错,提示文件1在备份,关闭不了。。第一反应是文件损坏了,需要介质恢复,但是相关的归档日志早已经被删掉了,恢复不了,于是一方面去找相关备份,一方面网上查询该问题,结果还真找着了,一句 alter database end backup; 解决了问题!!!原来是因为之前sap 的工具brtools发起的数据库备份,没有正常结束,导致数据文件scn被修改,停掉后正常启动了,真是到处都有坑呀。。

SQL> shutdown immediate
ORA-01149: cannot shutdown - file 1 has online backup set
ORA-01110: data file 1: /oracle/RED/sapdata1/system_1/system.data1
SQL> shutdown immediate
ORA-01149: cannot shutdown - file 1 has online backup set
ORA-01110: data file 1: /oracle/RED/sapdata1/system_1/system.data1
SQL>
SQL> startup force
ORACLE instance started.

Total System Global Area 2902458368 bytes
Fixed Size                  2074088 bytes
Variable Size            1459620376 bytes
Database Buffers         1426063360 bytes
Redo Buffers               14700544 bytes
Database mounted.
ORA-01113: file 1 needs media recovery
ORA-01110: data file 1: /oracle/RED/sapdata1/system_1/system.data1


SQL> select open_mode from v$database;

OPEN_MODE
----------
MOUNTED

SQL> 
SQL> 
SQL> alter database open;
alter database open
*
ERROR at line 1:
ORA-01113: file 1 needs media recovery
ORA-01110: data file 1: /oracle/RED/sapdata1/system_1/system.data1SQL> 
SQL> recover datafile 1
ORA-00279: change 1414625596 generated at 04/10/2016 02:00:45 needed for thread 1
ORA-00289: suggestion : /oracle/RED/oraarch/1_118503_615654930.dbf
ORA-00280: change 1414625596 for thread 1 is in sequence #118503


Specify log: {<RET>=suggested | filename | AUTO | CANCEL}

ORA-00308: cannot open archived log /oracle/RED/oraarch/1_118503_615654930.dbf
ORA-27037: unable to obtain file status
IBM AIX RISC System/6000 Error: 2: No such file or directory
Additional information: 3


SQL>  select file#,status from v$datafile;

     FILE# STATUS
---------- -------
         1 SYSTEM
         2 ONLINE
         3 ONLINE

SQL> alter database end backup;    --解决问题了

Database altered.

SQL> alter database open;

Database altered.

SQL> select open_mode from v$database;

OPEN_MODE
----------
READ WRITE

 

测试库重启出来的问题

标签:导致   dia   hive   测试   buffers   instance   font   归档   arch   

原文地址:http://www.cnblogs.com/laosu8/p/6634992.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!