标签云
asm恢复 bbed bootstrap$ dul In Memory kcbzib_kcrsds_1 kccpb_sanity_check_2 MySQL恢复 ORA-00312 ORA-00607 ORA-00704 ORA-00742 ORA-01110 ORA-01555 ORA-01578 ORA-01595 ORA-08103 ORA-600 2131 ORA-600 2662 ORA-600 3020 ORA-600 4000 ORA-600 4137 ORA-600 4193 ORA-600 4194 ORA-600 16703 ORA-600 kcbzib_kcrsds_1 ORA-600 KCLCHKBLK_4 ORA-15042 ORA-15196 ORACLE 12C oracle dul ORACLE PATCH Oracle Recovery Tools oracle加密恢复 oracle勒索 oracle勒索恢复 oracle异常恢复 Oracle 恢复 ORACLE恢复 ORACLE数据库恢复 oracle 比特币 OSD-04016 YOUR FILES ARE ENCRYPTED 勒索恢复 比特币加密文章分类
- Others (2)
- 中间件 (2)
- WebLogic (2)
- 操作系统 (103)
- 数据库 (1,768)
- DB2 (22)
- MySQL (77)
- Oracle (1,609)
- Data Guard (52)
- EXADATA (8)
- GoldenGate (24)
- ORA-xxxxx (166)
- ORACLE 12C (72)
- ORACLE 18C (6)
- ORACLE 19C (15)
- ORACLE 21C (3)
- Oracle 23ai (8)
- Oracle ASM (69)
- Oracle Bug (8)
- Oracle RAC (54)
- Oracle 安全 (6)
- Oracle 开发 (28)
- Oracle 监听 (29)
- Oracle备份恢复 (591)
- Oracle安装升级 (97)
- Oracle性能优化 (62)
- 专题索引 (5)
- 勒索恢复 (86)
- PostgreSQL (30)
- pdu工具 (6)
- PostgreSQL恢复 (9)
- SQL Server (32)
- SQL Server恢复 (13)
- TimesTen (7)
- 达梦数据库 (3)
- 达梦恢复 (1)
- 生活娱乐 (2)
- 至理名言 (11)
- 虚拟化 (2)
- VMware (2)
- 软件开发 (39)
- Asp.Net (9)
- JavaScript (12)
- PHP (2)
- 小工具 (22)
-
最近发表
- ORA-600 kokiasg1故障分析(obj$中核心字典序列全部被恶意删除)
- ORA-00756 ORA-10567故障数据0丢失恢复
- 数据库文件变成32k故障恢复
- tcp连接过多导致监听TNS-12532 TNS-12560 TNS-00502错误
- 文件系统格式化MySQL数据库恢复
- .sstop勒索加密数据库恢复
- 解决一次硬件恢复之后数据文件0kb的故障恢复case
- Error in invoking target ‘libasmclntsh19.ohso libasmperl19.ohso client_sharedlib’问题处理
- ORA-01171: datafile N going offline due to error advancing checkpoint
- linux环境oracle数据库被文件系统勒索加密为.babyk扩展名溯源
- ORA-600 ksvworkmsgalloc: bad reaper
- ORA-600 krccfl_chunk故障处理
- Oracle Recovery Tools恢复案例总结—202505
- ORA-600 kddummy_blkchk 数据库循环重启
- 记录一次asm disk加入到vg通过恢复直接open库的案例
- CHECKDB 发现了 N 个分配错误和 M 个一致性错误
- 达梦数据库dm.ctl文件异常恢复
- Oracle Recovery Tools修复ORA-00742、ORA-600 ktbair2: illegal inheritance故障
- 可能是 tempdb 空间用尽或某个系统表不一致故障处理
- 11.2.0.4库中遇到ORA-600 kcratr_nab_less_than_odr报错
分类目录归档:ORA-xxxxx
因asm sga_target设置不当导致11gr2 rac无法正常启动
2014年第一个故障排查和解决:同事反馈给我说solaris 11.2 两节点rac无法启动,让我帮忙看下。通过分析是因为sga_target参数设置不合理导致asm无法正常启动
GI无法正常启动
grid@zwq-rpt1:~$crsctl status resource -t CRS-4535: Cannot communicate with Cluster Ready Services CRS-4000: Command Status failed, or completed with errors. grid@zwq-rpt1:~$crsctl status resource -t -init -------------------------------------------------------------------------------- NAME TARGET STATE SERVER STATE_DETAILS -------------------------------------------------------------------------------- Cluster Resources -------------------------------------------------------------------------------- ora.asm 1 ONLINE OFFLINE Instance Shutdown ora.cluster_interconnect.haip 1 ONLINE ONLINE zwq-rpt1 ora.crf 1 ONLINE ONLINE zwq-rpt1 ora.crsd 1 ONLINE OFFLINE ora.cssd 1 ONLINE ONLINE zwq-rpt1 ora.cssdmonitor 1 ONLINE ONLINE zwq-rpt1 ora.ctssd 1 ONLINE ONLINE zwq-rpt1 ACTIVE:0 ora.diskmon 1 OFFLINE OFFLINE ora.evmd 1 ONLINE INTERMEDIATE zwq-rpt1 ora.gipcd 1 ONLINE ONLINE zwq-rpt1 ora.gpnpd 1 ONLINE ONLINE zwq-rpt1 ora.mdnsd 1 ONLINE ONLINE zwq-rpt1
asm未正常启动
GI日志报错
2014-01-01 00:40:47.708 [cssd(1418)]CRS-1605:CSSD voting file is online: /dev/rdsk/emcpower0a; details in /export/home/app/grid/log/zwq-rpt1/cssd/ocssd.log. 2014-01-01 00:40:53.234 [cssd(1418)]CRS-1601:CSSD Reconfiguration complete. Active nodes are zwq-rpt1 zwq-rpt2 . 2014-01-01 00:40:56.659 [ctssd(1483)]CRS-2407:The new Cluster Time Synchronization Service reference node is host zwq-rpt2. 2014-01-01 00:40:56.661 [ctssd(1483)]CRS-2401:The Cluster Time Synchronization Service started on host zwq-rpt1. 2014-01-01 00:41:02.016 [ctssd(1483)]CRS-2408:The clock on host zwq-rpt1 has been updated by the Cluster Time Synchronization Service to be synchronous with the mean cluster time. 2014-01-01 00:43:23.874 [/export/home/app/grid/bin/oraagent.bin(1348)]CRS-5019:All OCR locations are on ASM disk groups [], and none of these disk groups are mounted. Details are at "(:CLSN00100:)" in "/export/home/app/grid/log/zwq-rpt1/agent/ohasd/oraagent_grid/oraagent_grid.log". 2014-01-01 00:45:42.837 [/export/home/app/grid/bin/oraagent.bin(1348)]CRS-5019:All OCR locations are on ASM disk groups [], and none of these disk groups are mounted. Details are at "(:CLSN00100:)" in "/export/home/app/grid/log/zwq-rpt1/agent/ohasd/oraagent_grid/oraagent_grid.log". 2014-01-01 00:48:02.087 [/export/home/app/grid/bin/oraagent.bin(1348)]CRS-5019:All OCR locations are on ASM disk groups [], and none of these disk groups are mounted. Details are at "(:CLSN00100:)" in "/export/home/app/grid/log/zwq-rpt1/agent/ohasd/oraagent_grid/oraagent_grid.log". 2014-01-01 00:48:18.836 [ohasd(1083)]CRS-2807:Resource 'ora.asm' failed to start automatically. 2014-01-01 00:48:18.837 [ohasd(1083)]CRS-2807:Resource 'ora.crsd' failed to start automatically. 2014-01-01 01:05:15.396 [/export/home/app/grid/bin/oraagent.bin(1348)]CRS-5019:All OCR locations are on ASM disk groups [CRSDG], and none of these disk groups are mounted. Details are at "(:CLSN00100:)" in "/export/home/app/grid/log/zwq-rpt1/agent/ohasd/oraagent_grid/oraagent_grid.log". 2014-01-01 01:05:45.101 [/export/home/app/grid/bin/oraagent.bin(1348)]CRS-5019:All OCR locations are on ASM disk groups [CRSDG], and none of these disk groups are mounted. Details are at "(:CLSN00100:)" in "/export/home/app/grid/log/zwq-rpt1/agent/ohasd/oraagent_grid/oraagent_grid.log". 2014-01-01 01:06:15.104 [/export/home/app/grid/bin/oraagent.bin(1348)]CRS-5019:All OCR locations are on ASM disk groups [CRSDG], and none of these disk groups are mounted. Details are at "(:CLSN00100:)" in "/export/home/app/grid/log/zwq-rpt1/agent/ohasd/oraagent_grid/oraagent_grid.log".
这里较为明显的看到,因为asm磁盘组异常导致ocr无法被访问导致crs无法正常启动
ORAAGENT日志
2014-01-01 00:43:23.870: [ora.asm][9] {0:0:2} [start] InstConnection::connectInt (2) Exception OCIException 2014-01-01 00:43:23.870: [ora.asm][9] {0:0:2} [start] InstConnection:connect:excp OCIException OCI error 604 2014-01-01 00:43:23.870: [ora.asm][9] {0:0:2} [start] DgpAgent::queryDgStatus excp ORA-00604: error occurred at recursive SQL level 1 ORA-04031: unable to allocate 32 bytes of shared memory ("shared pool","unknown object","KGLH0^34f764db","kglHeapInitialize:temp")
报了较为清晰的ORA-4031错误,检查asm日志
ASM日志报错
Wed Jan 01 00:47:33 2014 ORACLE_BASE not set in environment. It is recommended that ORACLE_BASE be set in the environment Reusing ORACLE_BASE from an earlier startup = /export/home/app/oracle Wed Jan 01 00:47:39 2014 Errors in file /export/home/app/oracle/diag/asm/+asm/+ASM1/trace/+ASM1_ora_1728.trc (incident=291447): ORA-04031: unable to allocate 32 bytes of shared memory ("shared pool","unknown object","KGLH0^34f764db","kglHeapInitialize:temp") Incident details in: /export/home/app/oracle/diag/asm/+asm/+ASM1/incident/incdir_291447/+ASM1_ora_1728_i291447.trc Wed Jan 01 00:47:48 2014 Dumping diagnostic data in directory=[cdmp_20140101004748], requested by (instance=1, osid=1728), summary=[incident=291447]. Use ADRCI or Support Workbench to package the incident. See Note 411.1 at My Oracle Support for error and packaging details. Wed Jan 01 00:47:53 2014 Errors in file /export/home/app/oracle/diag/asm/+asm/+ASM1/trace/+ASM1_ora_1730.trc (incident=291448): ORA-04031: unable to allocate 32 bytes of shared memory ("shared pool","unknown object","KGLH0^34f764db","kglHeapInitialize:temp") Incident details in: /export/home/app/oracle/diag/asm/+asm/+ASM1/incident/incdir_291448/+ASM1_ora_1730_i291448.trc Wed Jan 01 00:48:01 2014 Dumping diagnostic data in directory=[cdmp_20140101004801], requested by (instance=1, osid=1730), summary=[incident=291448]. Use ADRCI or Support Workbench to package the incident. See Note 411.1 at My Oracle Support for error and packaging details. Wed Jan 01 00:48:07 2014 Errors in file /export/home/app/oracle/diag/asm/+asm/+ASM1/trace/+ASM1_ora_1732.trc (incident=291449): ORA-04031: unable to allocate 32 bytes of shared memory ("shared pool","unknown object","KGLH0^34f764db","kglHeapInitialize:temp") Incident details in: /export/home/app/oracle/diag/asm/+asm/+ASM1/incident/incdir_291449/+ASM1_ora_1732_i291449.trc Wed Jan 01 00:48:16 2014 Dumping diagnostic data in directory=[cdmp_20140101004816], requested by (instance=1, osid=1732), summary=[incident=291449]. Use ADRCI or Support Workbench to package the incident. See Note 411.1 at My Oracle Support for error and packaging details. Wed Jan 01 00:48:16 2014 License high water mark = 1 USER (ospid: 1736): terminating the instance Instance terminated by USER, pid = 1736
这里可以清晰的看到,因为shared pool不足,导致asm报ora-4031错误,从而使得asm无法正常启动
分析原因
Starting up: Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production With the Real Application Clusters and Automatic Storage Management options. ORACLE_HOME = /export/home/app/grid System name: SunOS Node name: zwq-rpt1 Release: 5.11 Version: 11.1 Machine: sun4v Using parameter settings in server-side spfile +CRSDG/zwq-rpt-cluster/asmparameterfile/registry.253.823992831 System parameters with non-default values: sga_max_size = 2G large_pool_size = 16M instance_type = "asm" sga_target = 0 remote_login_passwordfile= "EXCLUSIVE" asm_diskstring = "/dev/rdsk/*" asm_diskgroups = "FRADG" asm_diskgroups = "DATADG" asm_power_limit = 1 diagnostic_dest = "/export/home/app/oracle"
这里可以看到sga_target被设置为了0,而shared pool又未被配置,这里因为shared pool不足从而出现了ORA-4031,从而导致crs在启动asm的过程失败,从而使得ocr不能被访问,进而使得crs不能正常启动.
处理方法
1.编辑pfile
grid@zwq-rpt1:/export/home/app/oracle/diag/asm/+asm/+ASM1/trace$vi /tmp/asm.pfile memory_target = 2G large_pool_size = 16M instance_type = "asm" sga_target = 0 remote_login_passwordfile= "EXCLUSIVE" asm_diskstring = "/dev/rdsk/*" asm_diskgroups = "FRADG" asm_diskgroups = "DATADG" asm_power_limit = 1 diagnostic_dest = "/export/home/app/oracle"
2.启动asm
grid@zwq-rpt1:/export/home/app/oracle/diag/asm/+asm/+ASM1/trace$sqlplus / as sysasm SQL*Plus: Release 11.2.0.3.0 Production on Wed Jan 1 01:04:10 2014 Copyright (c) 1982, 2011, Oracle. All rights reserved. Connected to an idle instance. SQL> startup pfile='/tmp/asm.pfile' ASM instance started Total System Global Area 2138521600 bytes Fixed Size 2161024 bytes Variable Size 2102806144 bytes ASM Cache 33554432 bytes ASM diskgroups mounted
3. 创建spfile
SQL> create spfile='+CRSDG' FROM PFILE='/tmp/asm.pfile'; File created. --asm alert日志 Wed Jan 01 01:08:59 2014 NOTE: updated gpnp profile ASM SPFILE to NOTE: updated gpnp profile ASM diskstring: /dev/rdsk/* NOTE: updated gpnp profile ASM diskstring: /dev/rdsk/* NOTE: updated gpnp profile ASM SPFILE to +CRSDG/zwq-rpt-cluster/asmparameterfile/registry.253.835664939
4. 关闭asm
SQL> shutdown immediate ORA-15097: cannot SHUTDOWN ASM instance with connected client (process 1971) SQL> shutdown abort ASM instance shutdown
5. 重启crs
root@zwq-rpt1:~# crsctl stop crs -f root@zwq-rpt1:~# crsctl start crs
6. 重启其他节点crs
root@zwq-rpt2:~# crsctl stop crs -f root@zwq-rpt2:~# crsctl start crs
7. 检查结果
root@zwq-rpt1:~# crsctl status res -t -------------------------------------------------------------------------------- NAME TARGET STATE SERVER STATE_DETAILS -------------------------------------------------------------------------------- Local Resources -------------------------------------------------------------------------------- ora.CRSDG.dg ONLINE ONLINE zwq-rpt1 ONLINE ONLINE zwq-rpt2 ora.DATADG.dg ONLINE ONLINE zwq-rpt1 ONLINE ONLINE zwq-rpt2 ora.FRADG.dg ONLINE ONLINE zwq-rpt1 ONLINE ONLINE zwq-rpt2 ora.LISTENER.lsnr ONLINE ONLINE zwq-rpt1 ONLINE ONLINE zwq-rpt2 ora.asm ONLINE ONLINE zwq-rpt1 Started ONLINE ONLINE zwq-rpt2 Started ora.gsd OFFLINE OFFLINE zwq-rpt1 OFFLINE OFFLINE zwq-rpt2 ora.net1.network ONLINE ONLINE zwq-rpt1 ONLINE ONLINE zwq-rpt2 ora.ons ONLINE ONLINE zwq-rpt1 ONLINE ONLINE zwq-rpt2 -------------------------------------------------------------------------------- Cluster Resources -------------------------------------------------------------------------------- ora.LISTENER_SCAN1.lsnr 1 ONLINE ONLINE zwq-rpt1 ora.cvu 1 ONLINE ONLINE zwq-rpt1 ora.oc4j 1 ONLINE ONLINE zwq-rpt1 ora.rptdb.db 1 ONLINE ONLINE zwq-rpt1 Open 2 ONLINE ONLINE zwq-rpt2 Open ora.scan1.vip 1 ONLINE ONLINE zwq-rpt1 ora.zwq-rpt1.vip 1 ONLINE ONLINE zwq-rpt1 ora.zwq-rpt2.vip 1 ONLINE ONLINE zwq-rpt2
至此恢复正常,2014年第一个故障顺利解决
因RAC的undo_management参数不一致导致数据库mount报ORA-01105 ORA-01606
环境Linux 5.8 10.2.0.5 RAC,两个节点只能一个节点mount,如果尝试mount另外节点就报ORA-01105和ORA-01606错误
数据库版本
SQL> select * from v$version; BANNER ---------------------------------------------------------------- Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bi PL/SQL Release 10.2.0.5.0 - Production CORE 10.2.0.5.0 Production TNS for Linux: Version 10.2.0.5.0 - Production NLSRTL Version 10.2.0.5.0 - Production
crs资源情况
[oracle@node1 dbs]$ $ORA_CRS_HOME/bin/crs_stat -t Name Type Target State Host ------------------------------------------------------------ ora....D1.inst application OFFLINE OFFLINE ora....D2.inst application ONLINE ONLINE node2 ora.PROD.db application ONLINE ONLINE node2 ora....SM1.asm application ONLINE ONLINE node1 ora....E1.lsnr application ONLINE ONLINE node1 ora.node1.gsd application ONLINE ONLINE node1 ora.node1.ons application ONLINE ONLINE node1 ora.node1.vip application ONLINE ONLINE node1 ora....SM2.asm application ONLINE ONLINE node2 ora....E2.lsnr application ONLINE ONLINE node2 ora.node2.gsd application ONLINE ONLINE node2 ora.node2.ons application ONLINE ONLINE node2 ora.node2.vip application ONLINE ONLINE node2
节点1 mount报错
SQL> startup ORACLE instance started. Total System Global Area 171966464 bytes Fixed Size 2094832 bytes Variable Size 113248528 bytes Database Buffers 50331648 bytes Redo Buffers 6291456 bytes ORA-01105: mount is incompatible with mounts by other instances ORA-01606: gc_files_to_locks not identical to that of another mounted instance
Error: ORA 1105 Text: mount is incompatible with mounts by other instances ------------------------------------------------------------------------------- Cause: An attempt was made to mount the database, but another instance has already mounted a database by the same name, and the mounts are not compatible. dditional messages will accompany this message to report why the mounts are incompatible. Action: See the accompanying messages for the appropriate action to take. Error: ORA 1606 Text: GC_FILES_TO_LOCKS not identical to that of another mounted instance ------------------------------------------------------------------------------- Cause: The initialization parameter GC_FILES_TO_LOCKS is not the same as another instance mounted in parallel mode. This parameter must be the same as that for all shared instances. Action: Modify the parameter to be compatible with the other instances, then shut down and restart the instance.
根据这个错误提示,查询两个节点的gc_files_to_locks参数,均为空值(默认值),也就是值相同
SQL> show parameter gc_files_to_locks; NAME TYPE VALUE ------------------------------------ ----------- ------------------------------ gc_files_to_locks string
检查两个节点的gc相关隐含参数,发现所有值也均一致
NAME DESCRIPTION VALUE ------------------------------ --------------------------------------------------------------------- ------- _gc_affinity_limit dynamic affinity limit 50 _gc_affinity_minimum dynamic affinity minimum activity per minute 6000 _gc_affinity_time if non zero, enable dynamic object affinity 10 _gc_async_memcpy if TRUE, use async memcpy FALSE _gc_check_bscn if TRUE, check for stale blocks TRUE _gc_coalesce_recovery_reads if TRUE, coalesce recovery reads TRUE _gc_defer_time how long to defer down converts for hot buffers 3 _gc_dissolve_undo_affinity if TRUE, dissolve undo affinity after an offline FALSE _gc_dynamic_affinity_locks if TRUE, get dynamic affinity locks TRUE _gc_element_percent global cache element percent 103 _gc_global_lru turn global lru off, make it automatic, or turn it on AUTO _gc_initiate_undo_affinity if TRUE, initiate undo affinity after an online TRUE _gc_integrity_checks set the integrity check level 1 _gc_keep_recovery_buffers if TRUE, make recovery buffers current TRUE _gc_latches number of latches per LMS process 8 _gc_maximum_bids maximum number of bids which can be prepared 0 _gcs_fast_reconfig if TRUE, enable fast reconfiguration for gcs locks TRUE _gcs_latches number of gcs resource hash latches to be allocated per LMS process 64 _gcs_pkey_history number of pkey remastering history 4000 _gcs_process_in_recovery if TRUE, process gcs requests during instance recovery TRUE _gcs_resources number of gcs resources to be allocated _gcs_shadow_locks number of pcm shadow locks to be allocated _gc_statistics if TRUE, kcl statistics are maintained TRUE _gcs_testing GCS testing parameter 0 _gc_tsn_undo_affinity if TRUE, use TSN undo affinity TRUE _gc_undo_affinity if TRUE, enable dynamic undo affinity TRUE _gc_undo_affinity_locks if TRUE, get affinity locks for undo TRUE _gc_use_cr if TRUE, allow CR pins on PI and WRITING buffers TRUE _gc_vector_read if TRUE, vector read current buffers TRUE
仔细对比数据库参数,发现undo异常
--节点1 SQL> show parameter undo NAME TYPE VALUE ------------------------------------ ----------- ------------------------------ undo_management string MANUAL undo_retention integer 900 undo_tablespace string SYSTEM --节点2 SQL> show parameter undo NAME TYPE VALUE ------------------------------------ ----------- ------------------------------ undo_management string AUTO undo_retention integer 900 undo_tablespace string UNDOTBS1
这里已经明确,因为两个节点的undo_*相关参数配置不正确,导致数据库只能一个节点mount。进一步定位问题发现,原来是因为dba粗心在编辑节点1的参数文件的时候把undo_*相关的参数给弄丢了,从而数据库使用了默认值undo_management=manual,undo_tablespace=system
重建控制文件丢失undo异常恢复—ORA-01173模拟与恢复
数据库异常关闭,使用resetlogs方式重建控制文件,不包含undo表空间相关数据库,然后尝试resetlogs打开数据库,非常容易出现ORA-01173: data dictionary indicates missing data file from system tablespace之类的错误,本文通过模拟该错误,并简单提供解决方法
模拟ORA-01173错误
SQL> select * from v$version; BANNER -------------------------------------------------------------------------------- Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - Production PL/SQL Release 11.2.0.3.0 - Production CORE 11.2.0.3.0 Production TNS for Linux: Version 11.2.0.3.0 - Production NLSRTL Version 11.2.0.3.0 - Production SQL> shutdown abort; ORACLE instance shut down. --除掉undo表空间相关数据库然后使用resetlogs模式重建控制文件 SQL> startup nomount; ORACLE instance started. Total System Global Area 175775744 bytes Fixed Size 1343668 bytes Variable Size 117444428 bytes Database Buffers 50331648 bytes Redo Buffers 6656000 bytes SQL> @/tmp/ctl.sql 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/oracle/oradata/ora11g/system01.dbf' SQL> recover database until cancel; ORA-00283: recovery session canceled due to errors ORA-01610: recovery using the BACKUP CONTROLFILE option must be done SQL> recover database until cancel using backup controlfile; ORA-00279: change 12696930512547 generated at 08/26/2013 14:43:13 needed for thread 1 ORA-00289: suggestion : /u01/oracle/oradata/ora11g/archivelog/1_8_824475918.dbf ORA-00280: change 12696930512547 for thread 1 is in sequence #8 Specify log: {<RET>=suggested | filename | AUTO | CANCEL} cancel; ORA-00308: cannot open archived log 'cancel;' ORA-27037: unable to obtain file status Linux Error: 2: No such file or directory Additional information: 3 Specify log: {<RET>=suggested | filename | AUTO | CANCEL} cancel 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/oracle/oradata/ora11g/system01.dbf' ORA-01112: media recovery not started 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/oracle/oradata/ora11g/system01.dbf' SQL> recover database until cancel using backup controlfile; ORA-00279: change 12696930512547 generated at 08/26/2013 14:43:13 needed for thread 1 ORA-00289: suggestion : /u01/oracle/oradata/ora11g/archivelog/1_8_824475918.dbf ORA-00280: change 12696930512547 for thread 1 is in sequence #8 Specify log: {<RET>=suggested | filename | AUTO | CANCEL} /u01/oracle/oradata/ora11g/redo02.log Log applied. Media recovery complete. SQL> alter database open resetlogs; alter database open resetlogs * ERROR at line 1: ORA-01092: ORACLE instance terminated. Disconnection forced ORA-01173: data dictionary indicates missing data file from system tablespace Process ID: 15053 Session ID: 125 Serial number: 3
alert日志
Mon Aug 26 15:22:20 2013 alter database open resetlogs RESETLOGS after complete recovery through change 12696930514503 Archived Log entry 1 added for thread 1 sequence 7 ID 0xfb91eb36 dest 1: Archived Log entry 2 added for thread 1 sequence 8 ID 0xfb91eb36 dest 1: Archived Log entry 3 added for thread 1 sequence 6 ID 0xfb91eb36 dest 1: Clearing online redo logfile 1 /u01/oracle/oradata/ora11g/redo01.log Clearing online log 1 of thread 1 sequence number 7 Clearing online redo logfile 1 complete Clearing online redo logfile 2 /u01/oracle/oradata/ora11g/redo02.log Clearing online log 2 of thread 1 sequence number 8 Clearing online redo logfile 2 complete Clearing online redo logfile 3 /u01/oracle/oradata/ora11g/redo03.log Clearing online log 3 of thread 1 sequence number 6 Clearing online redo logfile 3 complete Resetting resetlogs activation ID 4220644150 (0xfb91eb36) Online log /u01/oracle/oradata/ora11g/redo01.log: Thread 1 Group 1 was previously cleared Online log /u01/oracle/oradata/ora11g/redo02.log: Thread 1 Group 2 was previously cleared Online log /u01/oracle/oradata/ora11g/redo03.log: Thread 1 Group 3 was previously cleared Mon Aug 26 15:22:26 2013 Setting recovery target incarnation to 2 Using SCN growth rate of 16384 per second Mon Aug 26 15:22:26 2013 Assigning activation ID 4220652407 (0xfb920b77) LGWR: STARTING ARCH PROCESSES Mon Aug 26 15:22:26 2013 ARC0 started with pid=20, OS id=15131 ARC0: Archival started LGWR: STARTING ARCH PROCESSES COMPLETE ARC0: STARTING ARCH PROCESSES Mon Aug 26 15:22:27 2013 ARC1 started with pid=21, OS id=15135 Mon Aug 26 15:22:27 2013 ARC2 started with pid=22, OS id=15139 Thread 1 opened at log sequence 1 Current log# 1 seq# 1 mem# 0: /u01/oracle/oradata/ora11g/redo01.log Successful open of redo thread 1 MTTR advisory is disabled because FAST_START_MTTR_TARGET is not set Mon Aug 26 15:22:27 2013 SMON: enabling cache recovery Mon Aug 26 15:22:27 2013 ARC3 started with pid=23, OS id=15143 ARC1: Archival started ARC2: Archival started ARC2: Becoming the 'no FAL' ARCH ARC2: Becoming the 'no SRL' ARCH ARC1: Becoming the heartbeat ARCH Errors in file /u01/oracle/diag/rdbms/ora11g/ora11g/trace/ora11g_ora_15053.trc: ORA-01173: data dictionary indicates missing data file from system tablespace Errors in file /u01/oracle/diag/rdbms/ora11g/ora11g/trace/ora11g_ora_15053.trc: ORA-01173: data dictionary indicates missing data file from system tablespace Error 1173 happened during db open, shutting down database USER (ospid: 15053): terminating the instance due to error 1173 Instance terminated by USER, pid = 15053 ORA-1092 signalled during: alter database open resetlogs... opiodr aborting process unknown ospid (15053) as a result of ORA-1092 Mon Aug 26 15:22:29 2013 ORA-1092 : opitsk aborting process
解决方案
解决方案设置相关异常回滚段,然后屏蔽掉,数据库即可正常起来
--参数文件修改(使用event或者工具,系统命令等) undo_management='manual' _corrupted_rollback_segments --重启数据库使得_corrupted_rollback_segments生效 shutdown immediate; startup --尝试open数据库 recover database; alter database open; --新建undo create undo tablespace undo_new datafile '' size 100m autoextend on next 10m maxsize 30G; --删除老undo drop tablespace old_undo --修改参数 shutdonw immediate undo_management='auto' undo_tablespace='unod_new' --启动数据库 startup --逻辑导出数据,导入新库