_allow_resetlogs_corruption=TRUE 相当给力ORA-01194已成浮云

要restore databse, rman resstore好了但是db 怎么都open 不了
因为事情着急,所以直接用了传说中的隐藏参数_allow_resetlogs_corruption=TRUE

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: '/oracle/oradata/LFE/system01.dbf'


SQL> alter system set _allow_resetlogs_corruption=TRUE scope=spfile;
alter system set _allow_resetlogs_corruption=TRUE scope=spfile
*
ERROR at line 1:
ORA-00911: invalid character


SQL> show parameter pfile

NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
spfile string /oracle/product/10.2/db_1/dbs/
SQL> create pfile='/oracle/product/10.2/db_1/dbs/' from spfile;
create pfile='/oracle/product/10.2/db_1/dbs/' from spfile
*
ERROR at line 1:
ORA-07391: sftopn: fopen error, unable to open text file.


SQL> create pfile='/oracle/product/10.2/db_1/dbs/lfe_20101111_restore.ora' from spfile;

File created.

SQL> $
SP2-0042: unknown command "$" - rest of line ignored.
SQL> $
SP2-0042: unknown command "$" - rest of line ignored.
SQL> !
$ cd /oracle/product/10.2/db_1/dbs/
$ ls
alert_lferestore.log lfe_20101111_restore.ora orapworadb
hc_lfe.dat lkLFE snapcf_lfe.f
hc_lferestore.dat lkLFERESTO spfilelfe.ora
hc_orabd.dat lkLFERESTORE spfilelferestore.ora
hc_oradb.dat lkORADB spfileoradb.ora
"lfe_20101111_restore.ora" 28 lines, 924 characters
initdw.ora orapwlferestore
$ vi lfe_20101111_restore.ora

lfe.__db_cache_size=595591168
lfe.__java_pool_size=4194304
lfe.__large_pool_size=4194304
lfe.__db_cache_size=595591168
lfe.__java_pool_size=4194304
lfe.__large_pool_size=4194304
lfe.__shared_pool_size=318767104
lfe.__streams_pool_size=0
_allow_resetlogs_corruption=TRUE
*.audit_file_dest='/oracle/admin/lfe/adump'
lfe.__shared_pool_size=318767104
lfe.__streams_pool_size=0
*.audit_file_dest='/oracle/admin/lfe/adump'
*.audit_sys_operations=TRUE
*.audit_trail='DB'
*.background_dump_dest='/oracle/admin/lfe/bdump'
*.compatible='10.2.0.3.0'
*.control_files='/oracle/oradata/lfe/control01.ctl','/oracle/oradata/lfe/control
02.ctl','/oracle/oradata/lfe/control03.ctl'
*.core_dump_dest='/oracle/admin/lfe/cdump'
*.db_block_size=8192
*.db_domain=''
*.db_file_multiblock_read_count=16
*.db_name='lfe'
*.job_queue_processes=10
*.local_listener='LISTENER_LFE'
"lfe_20101111_restore.ora" 29 lines, 957 characters
$ exit

SQL> shutdwon immeidate;
SP2-0717: illegal SHUTDOWN option
SQL> shutdown immediate
ORA-01109: database not open


Database dismounted.
ORACLE instance shut down.
SQL> startup pfile=/oracle/product/10.2/db_1/dbs/lfe_20101111_restore.ora
ORACLE instance started.

Total System Global Area 931135488 bytes
Fixed Size 2060520 bytes
Variable Size 327159576 bytes
Database Buffers 595591168 bytes
Redo Buffers 6324224 bytes
Database mounted.
ORA-01589: must use RESETLOGS or NORESETLOGS option for database open


SQL> lfe_20101111_restore.ora
SP2-0042: unknown command "" - rest of line ignored.
SQL>
SQL> startup mount pfile=/oracle/product/10.2/db_1/dbs/lfe_20101111_restore.ora
ORA-01081: cannot start already-running ORACLE - shut it down first
SQL> shutdown immediate
ORA-01109: database not open


Database dismounted.
ORACLE instance shut down.
SQL> startup mount pfile=/oracle/product/10.2/db_1/dbs/lfe_20101111_restore.ora
ORACLE instance started.

Total System Global Area 931135488 bytes
Fixed Size 2060520 bytes
Variable Size 327159576 bytes
Database Buffers 595591168 bytes
Redo Buffers 6324224 bytes
Database mounted.
SQL> alter database open
2 ;
alter database open
*
ERROR at line 1:
ORA-01589: must use RESETLOGS or NORESETLOGS option for database open


SQL> alter database open resetlogs;

Database altered.

SQL> select * form v$instance;
select * fo v$instance
*
ERROR at line 1:
ORA-00923: FROM keyword not found where expected


SQL> select * from v$instance
2 ;

INSTANCE_NUMBER INSTANCE_NAME HOST_NAME VERSION STARTUP_T STATUS PAR THREAD# ARCHIVE LOG_SWITCH_WAIT LOGINS SHU DATABASE_STATUS INSTANCE_ROLE ACTIVE_ST BLO
--------------- ---------------- ---------------------------------------------------------------- ----------------- --------- ------------ --- ---------- ------- --------------- ---------- --- ----------------- ------------------ --------- ---
1 lfe cnlfecob 10.2.0.4.0 11-NOV-10 OPEN NO 1 STARTED ALLOWED NO ACTIVE PRIMARY_INSTANCE NORMAL NO

SQL>

[@more@] 还有一个方法应该是一个一个用
SQL> recover datafile N;
SQL> alter database open;
不过没做过尝试, 结果未知

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

转载于:http://blog.itpub.net/8337095/viewspace-1041314/

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

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

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值