重建控制文件的操作

[oracle@edgzrip1 trace]$ sqlplus / as sysdba

SQL*Plus: Release 11.2.0.3.0 Production on Fri Sep 15 17:01:14 2017

Copyright (c) 1982, 2011, Oracle. All rights reserved.

Connected to:

Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - Production

With the Partitioning, OLAP, Data Mining and Real Application Testing options

 

SQL>

SQL>

SQL>

SQL> select name from v$controlfile ;

 

NAME

-------------------------------------------------------------------------------

/u01/app/oracle/oradata/PROD1/control01.ctl

/u01/app/oracle/fast_recovery_area/PROD1/control02.ctl

SQL>

SQL>

SQL> ho rm /u01/app/oracle/oradata/PROD1/control01.ctl

SQL> ho rm /u01/app/oracle/fast_recovery_area/PROD1/control02.ctl

 

SQL> shutdown abort

ORACLE instance shut down.

SQL> startup

ORACLE instance started.

 

Total System Global Area 472887296 bytes

Fixed Size 1345716 bytes

Variable Size 419432268 bytes

Database Buffers 46137344 bytes

Redo Buffers 5971968 bytes

ORA-00205: error in identifying control file, check alert log for more info

 

SQL> CREATE CONTROLFILE REUSE DATABASE "PROD1" RESETLOGS FORCE LOGGING ARCHIVELOG

2 MAXLOGFILES 16

3 MAXLOGMEMBERS 3

4 MAXDATAFILES 100

5 MAXINSTANCES 8

6 MAXLOGHISTORY 292

7 LOGFILE

8 GROUP 1 '/u01/app/oracle/oradata/PROD1/redo01.log' SIZE 50M BLOCKSIZE 512,

9 GROUP 2 '/u01/app/oracle/oradata/PROD1/redo02.log' SIZE 50M BLOCKSIZE 512,

10 GROUP 3 '/u01/app/oracle/oradata/PROD1/redo03.log' SIZE 50M BLOCKSIZE 512

11 -- STANDBY LOGFILE

12 DATAFILE

13 '/u01/app/oracle/oradata/PROD1/system01.dbf',

14 '/u01/app/oracle/oradata/PROD1/sysaux01.dbf',

15 '/u01/app/oracle/oradata/PROD1/undotbs01.dbf',

16 '/u01/app/oracle/oradata/PROD1/users01.dbf',

17 '/u01/app/oracle/oradata/PROD1/example01.dbf',

18 '/u01/app/oracle/oradata/PROD1/undo01.dbf',

19 '/u01/practice/undotsb3.dbf'

20 CHARACTER SET WE8MSWIN1252;

Control file created.

SQL> alter database open resetlogs;

alter database open resetlogs

*

ERROR at line 1:

ORA-01194: file 1 needs more recovery to be consistent

ORA-01110: data file 1: '/u01/app/oracle/oradata/PROD1/system01.dbf'

 

SQL> recover database using backup controlfile until cancel;

ORA-00279: change 4833502 generated at 09/15/2017 15:19:37 needed for thread 1

ORA-00289: suggestion :

/u01/app/oracle/fast_recovery_area/PROD1/archivelog/2017_09_15/o1_mf_1_3_%u_.arc

ORA-00280: change 4833502 for thread 1 is in sequence #3

 

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

auto

ORA-00308: cannot open archived log

'/u01/app/oracle/fast_recovery_area/PROD1/archivelog/2017_09_15/o1_mf_1_3_%u_.ar

c'

ORA-27037: unable to obtain file status

Linux Error: 2: No such file or directory

Additional information: 3

 

ORA-00308: cannot open archived log

'/u01/app/oracle/fast_recovery_area/PROD1/archivelog/2017_09_15/o1_mf_1_3_%u_.ar

c'

ORA-27037: unable to obtain file status

Linux Error: 2: No such file or directory

Additional information: 3

 

ORA-01547: warning: RECOVER succeeded but OPEN RESETLOGS would get error below

ORA-01194: file 1 needs more recovery to be consistent

ORA-01110: data file 1: '/u01/app/oracle/oradata/PROD1/system01.dbf'

 

 

SQL> recover database using backup controlfile until cancel;

ORA-00279: change 4833502 generated at 09/15/2017 15:19:37 needed for thread 1

ORA-00289: suggestion :

/u01/app/oracle/fast_recovery_area/PROD1/archivelog/2017_09_15/o1_mf_1_3_%u_.arc

ORA-00280: change 4833502 for thread 1 is in sequence #3

 

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

/u01/app/oracle/oradata/PROD1/redo01.log

ORA-00310: archived log contains sequence 1; sequence 3 required

ORA-00334: archived log: '/u01/app/oracle/oradata/PROD1/redo01.log'

 

ORA-01547: warning: RECOVER succeeded but OPEN RESETLOGS would get error below

ORA-01194: file 1 needs more recovery to be consistent

ORA-01110: data file 1: '/u01/app/oracle/oradata/PROD1/system01.dbf'

 

SQL> /u01/app/oracle/oradata/PROD1/redo01.log

SP2-0734: unknown command beginning "/u01/app/o..." - rest of line ignored.

SQL> recover database using backup controlfile until cancel;

ORA-00279: change 4833502 generated at 09/15/2017 15:19:37 needed for thread 1

ORA-00289: suggestion :

/u01/app/oracle/fast_recovery_area/PROD1/archivelog/2017_09_15/o1_mf_1_3_%u_.arc

ORA-00280: change 4833502 for thread 1 is in sequence #3

 

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

/u01/app/oracle/oradata/PROD1/redo02.log

ORA-00310: archived log contains sequence 2; sequence 3 required

ORA-00334: archived log: '/u01/app/oracle/oradata/PROD1/redo02.log'

 

ORA-01547: warning: RECOVER succeeded but OPEN RESETLOGS would get error below

ORA-01194: file 1 needs more recovery to be consistent

ORA-01110: data file 1: '/u01/app/oracle/oradata/PROD1/system01.dbf'

 

SQL> recover database using backup controlfile until cancel;

ORA-00279: change 4833502 generated at 09/15/2017 15:19:37 needed for thread 1

ORA-00289: suggestion :

/u01/app/oracle/fast_recovery_area/PROD1/archivelog/2017_09_15/o1_mf_1_3_%u_.arc

ORA-00280: change 4833502 for thread 1 is in sequence #3

 

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

/u01/app/oracle/oradata/PROD1/redo03.log

Log applied.

Media recovery complete.

SQL>

SQL>

SQL>

SQL> alter database open resetlogs;

 

Database altered.

转载于:https://www.cnblogs.com/7798456shunqian/p/7527350.html

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

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值