标签云
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-08103 ORA-600 2131 ORA-600 2662 ORA-600 2663 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,716)
- DB2 (22)
- MySQL (74)
- Oracle (1,576)
- Data Guard (52)
- EXADATA (8)
- GoldenGate (24)
- ORA-xxxxx (160)
- ORACLE 12C (72)
- ORACLE 18C (6)
- ORACLE 19C (15)
- ORACLE 21C (3)
- Oracle 23ai (8)
- Oracle ASM (68)
- Oracle Bug (8)
- Oracle RAC (54)
- Oracle 安全 (6)
- Oracle 开发 (28)
- Oracle 监听 (28)
- Oracle备份恢复 (575)
- Oracle安装升级 (94)
- Oracle性能优化 (62)
- 专题索引 (5)
- 勒索恢复 (81)
- PostgreSQL (18)
- PostgreSQL恢复 (6)
- SQL Server (28)
- SQL Server恢复 (9)
- TimesTen (7)
- 达梦数据库 (2)
- 生活娱乐 (2)
- 至理名言 (11)
- 虚拟化 (2)
- VMware (2)
- 软件开发 (37)
- Asp.Net (9)
- JavaScript (12)
- PHP (2)
- 小工具 (20)
-
最近发表
- 不当使用_allow_resetlogs_corruption参数引起ORA-600 2662错误
- CSSD signal 11 in thread clssnmRcfgMgrThread故障处理
- 使用sid方式直接访问pdb(USE_SID_AS_SERVICE_LISTENER)
- ORA-00069: cannot acquire lock — table locks disabled for xxxx
- ORA-600 [4000] [a]相关bug
- sql server数据库“正在恢复”故障处理
- 如何判断数据文件是否处于begin backup状态
- CDM备份缺少归档打开数据库报ORA-600 kcbzib_kcrsds_1故障处理
- ORA-07445: exception encountered: core dump [expgod()+43] [IN_PAGE_ERROR]
- 2025年第一起ORA-600 16703故障恢复
- _gc_undo_affinity=FALSE触发ORA-01558
- public授权语句
- 中文环境显示AR8MSWIN1256(阿拉伯语字符集)
- 处理 Oracle 块损坏
- Oracle各种类型坏块说明和处理
- fio测试io,导致磁盘文件系统损坏故障恢复
- ORA-742 写丢失常见bug记录
- Oracle 19c 202501补丁(RUs+OJVM)-19.26
- 避免 19c 数据库性能问题需要考虑的事项 (Doc ID 3050476.1)
- Bug 21915719 Database hang or may fail to OPEN in 12c IBM AIX or HPUX Itanium – ORA-742, DEADLOCK or ORA-600 [kcrfrgv_nextlwn_scn] ORA-600 [krr_process_read_error_2]
标签归档:ORA-600 2662
不当使用_allow_resetlogs_corruption参数引起ORA-600 2662错误
有一个数据库由于机房掉电,导致数据库无法启动,由于不当恢复导致open过程报ORA-600 2662等错误客户无法自行解决,让我们协助.幸运的是客户对现场做了备份,我接手恢复之后,让客户还原现场,然后进行恢复,比较顺利的直接open数据库,实现数据0丢失原库直接可用,避免了一次因为不当操作而引起少量数据丢失的风险,和业务的快速恢复(避免的因为强制拉库引起的不一致性问题而要做数据库逻辑迁移).通过日志回顾第一次现场恢复经历
最初故障数据库mount报错
SQL> startup mount pfile='d:/pfile.txt' ORACLE 例程已经启动。 Total System Global Area 1071333376 bytes Fixed Size 1375792 bytes Variable Size 754975184 bytes Database Buffers 310378496 bytes Redo Buffers 4603904 bytes ORA-03113: 通信通道的文件结尾 进程 ID: 964 会话 ID: 1145 序列号: 1
无法mount,大部分情况是由于控制文件损坏,然后客户选择了重建controlfile
Thu Feb 20 10:20:45 2025 Successful mount of redo thread 1, with mount id 1721384698 Completed: CREATE CONTROLFILE REUSE DATABASE "ORCL" RESETLOGS ARCHIVELOG MAXLOGFILES 32 MAXLOGMEMBERS 2 MAXDATAFILES 254 MAXINSTANCES 1 MAXLOGHISTORY 226 LOGFILE GROUP 1 'D:\app\Administrator\oradata\orcl\redo01.log' size 50M, GROUP 2 'D:\app\Administrator\oradata\orcl\redo02.log' size 50M, GROUP 3 'D:\app\Administrator\oradata\orcl\redo03.log' size 50M DATAFILE 'D:\app\Administrator\oradata\orcl\XFF.DBF', 'D:\app\Administrator\oradata\orcl\XIFENFEI.DBF', 'D:\app\Administrator\oradata\orcl\SYSAUX01.DBF', 'D:\app\Administrator\oradata\orcl\SYSTEM01.DBF', 'D:\app\Administrator\oradata\orcl\UNDOTBS01.DBF', 'D:\app\Administrator\oradata\orcl\USERS01.DBF' CHARACTER SET ZHS16GBK
重建ctl使用了resetlogs模式,然后下一步客户进行恢复使用命令为:ALTER DATABASE RECOVER DATABASE UNTIL CANCEL USING BACKUP CONTROLFILE
Thu Feb 20 10:22:05 2025 ALTER DATABASE RECOVER DATABASE UNTIL CANCEL USING BACKUP CONTROLFILE Media Recovery Start started logmerger process Thu Feb 20 10:22:05 2025 WARNING! Recovering data file 1 from a fuzzy file. If not the current file it might be an online backup taken without entering the begin backup command. WARNING! Recovering data file 2 from a fuzzy file. If not the current file it might be an online backup taken without entering the begin backup command. WARNING! Recovering data file 3 from a fuzzy file. If not the current file it might be an online backup taken without entering the begin backup command. WARNING! Recovering data file 4 from a fuzzy file. If not the current file it might be an online backup taken without entering the begin backup command. WARNING! Recovering data file 5 from a fuzzy file. If not the current file it might be an online backup taken without entering the begin backup command. WARNING! Recovering data file 6 from a fuzzy file. If not the current file it might be an online backup taken without entering the begin backup command. Parallel Media Recovery started with 4 slaves ORA-279 signalled during: ALTER DATABASE RECOVER DATABASE UNTIL CANCEL USING BACKUP CONTROLFILE ... ALTER DATABASE RECOVER CONTINUE DEFAULT Media Recovery Log D:\APP\ADMINISTRATOR\FLASH_RECOVERY_AREA\ORCL\ARCHIVELOG\2025_02_20\O1_MF_1_9087_%U_.ARC Errors with log D:\APP\ADMINISTRATOR\FLASH_RECOVERY_AREA\ORCL\ARCHIVELOG\2025_02_20\O1_MF_1_9087_%U_.ARC Errors in file d:\app\administrator\diag\rdbms\orcl\orcl\trace\orcl_pr00_3044.trc: ORA-00308: cannot open archived log 'D:\APP\ADMINISTRATOR\FLASH_RECOVERY_AREA\ORCL\ARCHIVELOG\2025_02_20\O1_MF_1_9087_%U_.ARC' ORA-27041: unable to open file OSD-04002: 无法打开文件 O/S-Error: (OS 2) 系统找不到指定的文件。 ORA-308 signalled during: ALTER DATABASE RECOVER CONTINUE DEFAULT ... ALTER DATABASE RECOVER CONTINUE DEFAULT Media Recovery Log D:\APP\ADMINISTRATOR\FLASH_RECOVERY_AREA\ORCL\ARCHIVELOG\2025_02_20\O1_MF_1_9087_%U_.ARC Errors with log D:\APP\ADMINISTRATOR\FLASH_RECOVERY_AREA\ORCL\ARCHIVELOG\2025_02_20\O1_MF_1_9087_%U_.ARC Errors in file d:\app\administrator\diag\rdbms\orcl\orcl\trace\orcl_pr00_3044.trc: ORA-00308: cannot open archived log 'D:\APP\ADMINISTRATOR\FLASH_RECOVERY_AREA\ORCL\ARCHIVELOG\2025_02_20\O1_MF_1_9087_%U_.ARC' ORA-27041: unable to open file OSD-04002: 无法打开文件 O/S-Error: (OS 2) 系统找不到指定的文件。 ORA-308 signalled during: ALTER DATABASE RECOVER CONTINUE DEFAULT ... ALTER DATABASE RECOVER CANCEL Errors in file d:\app\administrator\diag\rdbms\orcl\orcl\trace\orcl_pr00_3044.trc: 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: 'D:\APP\ADMINISTRATOR\ORADATA\ORCL\SYSTEM01.DBF' ORA-10879 signalled during: ALTER DATABASE RECOVER CANCEL ...
直接提示需要找归档日志seq为9087的,但是由于该库为非归档模式,客户直接输入了auto,无法找到对应的日志.然后尝试直接resetlogs打开库
Thu Feb 20 10:22:58 2025 ALTER DATABASE OPEN RESETLOGS ORA-1194 signalled during: ALTER DATABASE OPEN RESETLOGS... ALTER DATABASE OPEN Errors in file d:\app\administrator\diag\rdbms\orcl\orcl\trace\orcl_ora_4836.trc: ORA-01589: ??????????? RESETLOGS ? NORESETLOGS ?? ORA-1589 signalled during: ALTER DATABASE OPEN... ALTER DATABASE OPEN RESETLOGS ORA-1194 signalled during: ALTER DATABASE OPEN RESETLOGS...
由于数据文件不一致(前面recover没有成功),导致直接reseltogs方式打开库失败,然后设置一些参数
Thu Feb 20 10:27:24 2025 ALTER SYSTEM SET _allow_error_simulation=TRUE SCOPE=SPFILE; ALTER SYSTEM SET _allow_terminal_recovery_corruption=TRUE SCOPE=SPFILE; Thu Feb 20 10:27:38 2025 ALTER SYSTEM SET _allow_resetlogs_corruption=TRUE SCOPE=SPFILE;
重启库之后强制拉库
Completed: alter database mount Thu Feb 20 10:29:08 2025 alter database open resetlogs RESETLOGS is being done without consistancy checks. This may result in a corrupted database. The database should be recreated. Thu Feb 20 10:29:19 2025 Archived Log entry 1 added for thread 1 sequence 9088 ID 0x5d904d0a dest 1: Archived Log entry 2 added for thread 1 sequence 9086 ID 0x5d904d0a dest 1: Thu Feb 20 10:29:31 2025 Archived Log entry 3 added for thread 1 sequence 9087 ID 0x5d904d0a dest 1: RESETLOGS after incomplete recovery UNTIL CHANGE 223770120 Thu Feb 20 10:29:38 2025 Setting recovery target incarnation to 2 Thu Feb 20 10:29:39 2025 Assigning activation ID 1721340650 (0x669992ea) LGWR: STARTING ARCH PROCESSES Thu Feb 20 10:29:39 2025 ARC0 started with pid=20, OS id=2924 ARC0: Archival started LGWR: STARTING ARCH PROCESSES COMPLETE ARC0: STARTING ARCH PROCESSES Thu Feb 20 10:29:40 2025 ARC1 started with pid=21, OS id=1832 Thu Feb 20 10:29:40 2025 ARC2 started with pid=22, OS id=3668 ARC1: Archival started Thu Feb 20 10:29:40 2025 ARC3 started with pid=23, OS id=5104 ARC2: Archival started ARC1: Becoming the 'no FAL' ARCH ARC1: Becoming the 'no SRL' ARCH ARC2: Becoming the heartbeat ARCH Thread 1 opened at log sequence 1 Current log# 1 seq# 1 mem# 0: D:\APP\ADMINISTRATOR\ORADATA\ORCL\REDO01.LOG Successful open of redo thread 1 Thu Feb 20 10:29:41 2025 MTTR advisory is disabled because FAST_START_MTTR_TARGET is not set Thu Feb 20 10:29:41 2025 SMON: enabling cache recovery ARC3: Archival started ARC0: STARTING ARCH PROCESSES COMPLETE Errors in file d:\app\administrator\diag\rdbms\orcl\orcl\trace\orcl_ora_1652.trc (incident=1006385): ORA-00600: ??????, ??: [2662], [0], [223770128], [0], [223811777], [12583040], [], [], [], [], [], [] Incident details in: d:\app\administrator\diag\rdbms\orcl\orcl\incident\incdir_1006385\orcl_ora_1652_i1006385.trc Errors in file d:\app\administrator\diag\rdbms\orcl\orcl\trace\orcl_ora_1652.trc: ORA-00600: ??????, ??: [2662], [0], [223770128], [0], [223811777], [12583040], [], [], [], [], [], [] Errors in file d:\app\administrator\diag\rdbms\orcl\orcl\trace\orcl_ora_1652.trc: ORA-00600: ??????, ??: [2662], [0], [223770128], [0], [223811777], [12583040], [], [], [], [], [], [] Error 600 happened during db open, shutting down database USER (ospid: 1652): terminating the instance due to error 600 Instance terminated by USER, pid = 1652
数据库报ORA-600 2662错误,导致强制拉库失败.
后面客户进行了一系列折腾,导致出现其他错误,比如:
ORA-01595/ORA-600 4194
Fri Feb 21 04:52:19 2025 Trace dumping is performing id=[cdmp_20250221045219] Doing block recovery for file 3 block 472 Resuming block recovery (PMON) for file 3 block 472 Block recovery from logseq 2, block 51 to scn 223837038 Recovery of Online Redo Log: Thread 1 Group 2 Seq 2 Reading mem 0 Mem# 0: D:\APP\ADMINISTRATOR\ORADATA\ORCL\REDO02.LOG Block recovery stopped at EOT rba 2.54.16 Block recovery completed at rba 2.54.16, scn 0.223837035 Doing block recovery for file 3 block 144 Resuming block recovery (PMON) for file 3 block 144 Block recovery from logseq 2, block 51 to scn 223837033 Recovery of Online Redo Log: Thread 1 Group 2 Seq 2 Reading mem 0 Mem# 0: D:\APP\ADMINISTRATOR\ORADATA\ORCL\REDO02.LOG Block recovery completed at rba 2.52.16, scn 0.223837034 Errors in file d:\app\administrator\diag\rdbms\orcl\orcl\trace\orcl_smon_2124.trc: ORA-01595: error freeing extent (3) of rollback segment (2)) ORA-00600: internal error code, arguments: [4194], [], [
ORA-600 2256/ORA-600 4194
Fri Feb 21 05:02:43 2025 SMON: enabling cache recovery Errors in file d:\app\administrator\diag\rdbms\orcl\orcl\trace\orcl_ora_2184.trc (incident=1134285): ORA-00600: 内部错误代码, 参数: [2256], [0], [1073741824], [0], [1073761870], [], [], [], [], [], [], [] Incident details in: d:\app\administrator\diag\rdbms\orcl\orcl\incident\incdir_1134285\orcl_ora_2184_i1134285.trc Successfully onlined Undo Tablespace 2. Verifying file header compatibility for 11g tablespace encryption.. Verifying 11g file header compatibility for tablespace encryption completed SMON: enabling tx recovery ********************************************************************* WARNING: The following temporary tablespaces contain no files. This condition can occur when a backup controlfile has been restored. It may be necessary to add files to these tablespaces. That can be done using the SQL statement: ALTER TABLESPACE <tablespace_name> ADD TEMPFILE Alternatively, if these temporary tablespaces are no longer needed, then they can be dropped. Empty temporary tablespace: TEMP ********************************************************************* Database Characterset is ZHS16GBK No Resource Manager plan active Errors in file d:\app\administrator\diag\rdbms\orcl\orcl\trace\orcl_smon_648.trc (incident=1134237): ORA-00600: internal error code, arguments: [4194], [], [ Incident details in: d:\app\administrator\diag\rdbms\orcl\orcl\incident\incdir_1134237\orcl_smon_648_i1134237.trc Errors in file d:\app\administrator\diag\rdbms\orcl\orcl\trace\orcl_ora_2184.trc (incident=1134286): ORA-00600: 内部错误代码, 参数: [4194], [0], [ Incident details in: d:\app\administrator\diag\rdbms\orcl\orcl\incident\incdir_1134286\orcl_ora_2184_i1134286.trc
ORA-600 3712
Fri Feb 21 05:24:51 2025 Assigning activation ID 1721440698 (0x669b19ba) Errors in file d:\app\administrator\diag\rdbms\orcl\orcl\trace\orcl_lgwr_3620.trc (incident=1150206): ORA-00600: internal error code, arguments: [3712], [1], [1], [3584], [3], [3584], [1], [], [], [], [], [] Incident details in: d:\app\administrator\diag\rdbms\orcl\orcl\incident\incdir_1150206\orcl_lgwr_3620_i1150206.trc Errors in file d:\app\administrator\diag\rdbms\orcl\orcl\trace\orcl_lgwr_3620.trc: ORA-00600: internal error code, arguments: [3712], [1], [1], [3584], [3], [3584], [1], [], [], [], [], [] LGWR (ospid: 3620): terminating the instance due to error 470
基于客户本身库不大,而且在操作之前备份了现场,然后客户还原故障现场备份,我开始接手恢复
重建控制文件
Fri Feb 21 21:57:19 2025 Successful mount of redo thread 1, with mount id 1721495486 Completed: CREATE CONTROLFILE REUSE DATABASE "ORCL" NORESETLOGS NOARCHIVELOG MAXLOGFILES 50 MAXLOGMEMBERS 5 MAXDATAFILES 5000 MAXINSTANCES 8 MAXLOGHISTORY 2920 LOGFILE group 1 'D:\APP\ADMINISTRATOR\ORADATA\ORCL\REDO01.LOG' size 50M, group 3 'D:\APP\ADMINISTRATOR\ORADATA\ORCL\REDO03.LOG' size 50M, group 2 'D:\APP\ADMINISTRATOR\ORADATA\ORCL\REDO02.LOG' size 50M DATAFILE 'D:\APP\ADMINISTRATOR\ORADATA\ORCL\SYSTEM01.DBF', 'D:\APP\ADMINISTRATOR\ORADATA\ORCL\SYSAUX01.DBF', 'D:\APP\ADMINISTRATOR\ORADATA\ORCL\UNDOTBS01.DBF', 'D:\APP\ADMINISTRATOR\ORADATA\ORCL\USERS01.DBF', 'D:\APP\ADMINISTRATOR\ORADATA\ORCL\XIFENFEI.DBF', 'D:\APP\ADMINISTRATOR\ORADATA\ORCL\XFF.DBF' CHARACTER SET ZHS16GBK
这里重建控制文件使用的是noresetlogs模式,然后尝试recover database
ALTER DATABASE RECOVER database Media Recovery Start started logmerger process Parallel Media Recovery started with 4 slaves Fri Feb 21 21:57:25 2025 Recovery of Online Redo Log: Thread 1 Group 3 Seq 9087 Reading mem 0 Mem# 0: D:\APP\ADMINISTRATOR\ORADATA\ORCL\REDO03.LOG Recovery of Online Redo Log: Thread 1 Group 1 Seq 9088 Reading mem 0 Mem# 0: D:\APP\ADMINISTRATOR\ORADATA\ORCL\REDO01.LOG Fri Feb 21 21:57:30 2025 Completed: ALTER DATABASE RECOVER database
数据库直接recover成功,然后尝试正常open库
Fri Feb 21 21:58:17 2025 alter database open Beginning crash recovery of 1 threads parallel recovery started with 3 processes Started redo scan Completed redo scan read 12019 KB redo, 0 data blocks need recovery Started redo application at Thread 1: logseq 9088, block 2, scn 223805802 Recovery of Online Redo Log: Thread 1 Group 1 Seq 9088 Reading mem 0 Mem# 0: D:\APP\ADMINISTRATOR\ORADATA\ORCL\REDO01.LOG Completed redo application of 0.00MB Completed crash recovery at Thread 1: logseq 9088, block 24040, scn 223836931 0 data blocks read, 0 data blocks written, 12019 redo k-bytes read Fri Feb 21 21:58:17 2025 Thread 1 advanced to log sequence 9089 (thread open) Thread 1 opened at log sequence 9089 Current log# 2 seq# 9089 mem# 0: D:\APP\ADMINISTRATOR\ORADATA\ORCL\REDO02.LOG Successful open of redo thread 1 MTTR advisory is disabled because FAST_START_MTTR_TARGET is not set Fri Feb 21 21:58:17 2025 SMON: enabling cache recovery Dictionary check beginning Tablespace 'TEMP' #3 found in data dictionary, but not in the controlfile. Adding to controlfile. Dictionary check complete Verifying file header compatibility for 11g tablespace encryption.. Verifying 11g file header compatibility for tablespace encryption completed SMON: enabling tx recovery ********************************************************************* WARNING: The following temporary tablespaces contain no files. This condition can occur when a backup controlfile has been restored. It may be necessary to add files to these tablespaces. That can be done using the SQL statement: ALTER TABLESPACE <tablespace_name> ADD TEMPFILE Alternatively, if these temporary tablespaces are no longer needed, then they can be dropped. Empty temporary tablespace: TEMP ********************************************************************* Database Characterset is ZHS16GBK No Resource Manager plan active ********************************************************** WARNING: Files may exists in db_recovery_file_dest that are not known to the database. Use the RMAN command CATALOG RECOVERY AREA to re-catalog any such files. If files cannot be cataloged, then manually delete them using OS command. One of the following events caused this: 1. A backup controlfile was restored. 2. A standby controlfile was restored. 3. The controlfile was re-created. 4. db_recovery_file_dest had previously been enabled and then disabled. ********************************************************** replication_dependency_tracking turned off (no async multimaster replication found) Starting background process QMNC Fri Feb 21 21:58:20 2025 QMNC started with pid=22, OS id=524 LOGSTDBY: Validating controlfile with logical metadata LOGSTDBY: Validation complete Completed: alter database open
数据库完美打开,然后增加tempfile,检查/导出数据均没有任何问题,业务可以直接使用本库,不用逻辑迁移
其实这是一个比较小的故障,由于断电导致控制文件损坏,然后客户重建控制文件使用resetlogs方式,然后recover没有正确指定redo,来完成数据库实例恢复,直接使用_allow_resetlogs_corruption参数强制拉库,然后出现了ORA-600 2662/ORA-600 4194/ORA-600 2256等大家熟悉的错误.这个库不大,也做了故障现场保护,如果是一个10T以上大库,发生这样的故障,后果还是比较麻烦的(库可以打开,但是redo中的数据肯定丢失导致数据库不一致,后续可能有很多不一致性问题,可能涉及逻辑迁移),增加企业业务不可用时间成本和业务数据丢失风险,再次提醒对于Oracle隐含参数,还是需要慎重,做好专业的评估再使用.
通过alert日志分析客户自行对一个数据库恢复的来龙去脉和点评
12.1.0.2数据库由于异常断电,导致无法正常启动,通过alert日志对客户的整个操作过程进行分析(不含我的操作部分)
通过alert日志分析最初故障原因是由于控制文件有坏块导致
Tue Sep 24 11:49:48 2024 alter database open Tue Sep 24 11:49:48 2024 Ping without log force is disabled . Tue Sep 24 11:49:48 2024 Errors in file /u01/app/oracle/diag/rdbms/orcl/orcl/trace/orcl_ora_4715.trc: ORA-01113: file 10 needs media recovery ORA-01110: data file 10: '/u01/app/oracle/oradata/xifenfei.dbf' ORA-1113 signalled during: alter database open... alter database recover datafile '/u01/app/oracle/oradata/xifenfei.dbf'
offline 无法正常recover的数据文件
Tue Sep 24 13:13:30 2024 Media Recovery Complete (orcl) Completed: ALTER DATABASE RECOVER datafile 15 ALTER DATABASE DATAFILE '/u01/app/oracle/oradata/xifenfei.dbf' END BACKUP ORA-1235 signalled during: ALTER DATABASE DATAFILE '/u01/app/oracle/oradata/xifenfei.dbf' END BACKUP... ALTER DATABASE DATAFILE '/u01/app/oracle/oradata/xifenfei.dbf' offline Completed: ALTER DATABASE DATAFILE '/u01/app/oracle/oradata/xifenfei.dbf' offline Tue Sep 24 13:25:16 2024 ALTER DATABASE DATAFILE '/u01/app/oracle/oradata/xff.dbf' offline Completed: ALTER DATABASE DATAFILE '/u01/app/oracle/oradata/xff.dbf' offline
然后尝试打开数据库,遭遇ORA-600 4193错误,没有open成功
Tue Sep 24 13:27:06 2024 Media Recovery Complete (orcl) Completed: ALTER DATABASE RECOVER datafile 13 alter database open Tue Sep 24 13:27:16 2024 Ping without log force is disabled . Tue Sep 24 13:27:16 2024 Beginning crash recovery of 1 threads parallel recovery started with 7 processes Tue Sep 24 13:27:16 2024 Started redo scan Tue Sep 24 13:27:16 2024 Completed redo scan read 67 KB redo, 0 data blocks need recovery Tue Sep 24 13:27:16 2024 Started redo application at Thread 1: logseq 7422, block 2, scn 119284797 Tue Sep 24 13:27:16 2024 Recovery of Online Redo Log: Thread 1 Group 3 Seq 7422 Reading mem 0 Mem# 0: /u01/app/oracle/oradata/orcl/redo03.log Tue Sep 24 13:27:16 2024 Completed redo application of 0.00MB Tue Sep 24 13:27:16 2024 Completed crash recovery at Thread 1: logseq 7422, block 136, scn 119284798 0 data blocks read, 0 data blocks written, 67 redo k-bytes read Initializing SCN for created control file Database SCN compatibility initialized to 3 Starting background process TMON Tue Sep 24 13:27:16 2024 TMON started with pid=32, OS id=10617 Tue Sep 24 13:27:16 2024 Thread 1 advanced to log sequence 7423 (thread open) Thread 1 opened at log sequence 7423 Current log# 1 seq# 7423 mem# 0: /u01/app/oracle/oradata/orcl/redo01.log Successful open of redo thread 1 Tue Sep 24 13:27:16 2024 MTTR advisory is disabled because FAST_START_MTTR_TARGET is not set Tue Sep 24 13:27:16 2024 SMON: enabling cache recovery Tue Sep 24 13:27:20 2024 [10553] Successfully onlined Undo Tablespace 2. Undo initialization finished serial:0 start:6974064 end:6975474 diff:1410 ms (1.4 seconds) Dictionary check beginning Tablespace 'TEMP' #3 found in data dictionary, but not in the controlfile. Adding to controlfile. File #10 is offline, but is part of an online tablespace. data file 10: '/u01/app/oracle/oradata/tbs_data.dbf' File #14 is offline, but is part of an online tablespace. data file 14: '/u01/app/oracle/oradata/corsmf03.dbf' Dictionary check complete Verifying minimum file header compatibility (11g) for tablespace encryption.. Verifying 11g file header compatibility for tablespace encryption completed Tue Sep 24 13:27:21 2024 SMON: enabling tx recovery Tue Sep 24 13:27:21 2024 ********************************************************************* WARNING: The following temporary tablespaces contain no files. This condition can occur when a backup controlfile has been restored. It may be necessary to add files to these tablespaces. That can be done using the SQL statement: ALTER TABLESPACE <tablespace_name> ADD TEMPFILE Alternatively, if these temporary tablespaces are no longer needed, then they can be dropped. Empty temporary tablespace: TEMP ********************************************************************* Updating character set in controlfile to AL32UTF8 Starting background process SMCO Tue Sep 24 13:27:21 2024 SMCO started with pid=34, OS id=10632 Errors in file /u01/app/oracle/diag/rdbms/orcl/orcl/trace/orcl_smon_10523.trc (incident=108129): ORA-00600: internal error code, arguments: [4193], [21368], [21372], [], [], [], [], [], [], [], [], [] Incident details in:/u01/app/oracle/diag/rdbms/orcl/orcl/incident/incdir_108129/orcl_smon_10523_i108129.trc Use ADRCI or Support Workbench to package the incident. See Note 411.1 at My Oracle Support for error and packaging details. ………… Tue Sep 24 13:27:24 2024 Errors in file /u01/app/oracle/diag/rdbms/orcl/orcl/trace/orcl_ora_10553.trc: ORA-00600: internal error code, arguments: [4193], [21652], [21539], [], [] Tue Sep 24 13:27:24 2024 Errors in file /u01/app/oracle/diag/rdbms/orcl/orcl/trace/orcl_ora_10553.trc: ORA-00600: internal error code, arguments: [4193], [21652], [21539], [], [] Error 600 happened during db open, shutting down database USER (ospid: 10553): terminating the instance due to error 600 Tue Sep 24 13:27:25 2024 Instance terminated by USER, pid = 10553 ORA-1092 signalled during: alter database open...
重建了ctl,加入_allow_resetlogs_corruption隐含参数,尝试使用resetlogs方式打开数据库,报ORA-600 2662错误
Tue Sep 24 14:30:22 2024 alter database open RESETLOGS Tue Sep 24 14:32:09 2024 RESETLOGS is being done without consistancy checks. This may result in a corrupted database. The database should be recreated. RESETLOGS after incomplete recovery UNTIL CHANGE 119237645 time Online log /u01/app/oracle/oradata/orcl/redo01.log: Thread 1 Group 1 was previously cleared Online log /u01/app/oracle/oradata/orcl/redo02.log: Thread 1 Group 2 was previously cleared Online log /u01/app/oracle/oradata/orcl/redo03.log: Thread 1 Group 3 was previously cleared Tue Sep 24 14:32:09 2024 Setting recovery target incarnation to 2 Tue Sep 24 14:32:09 2024 Ping without log force is disabled . Initializing SCN for created control file Database SCN compatibility initialized to 3 Tue Sep 24 14:32:09 2024 Warning - High Database SCN: Current SCN value is 119237648, threshold SCN value is 0 If you have not previously reported this warning on this database, please notify Oracle Support so that additional diagnosis can be performed. Starting background process TMON Tue Sep 24 14:32:09 2024 TMON started with pid=25, OS id=15032 Tue Sep 24 14:32:09 2024 Assigning activation ID 1708301307 (0x65d29bfb) Thread 1 opened at log sequence 1 Current log# 1 seq# 1 mem# 0: /u01/app/oracle/oradata/orcl/redo01.log Successful open of redo thread 1 Tue Sep 24 14:32:09 2024 MTTR advisory is disabled because FAST_START_MTTR_TARGET is not set Tue Sep 24 14:32:09 2024 SMON: enabling cache recovery Errors in file /u01/app/oracle/diag/rdbms/orcl/orcl/trace/orcl_ora_14937.trc (incident=122458): ORA-00600: internal error code, arguments: [2662], [0], [119484861], [0], [119484868], [16777344]…… Incident details in: /u01/app/oracle/diag/rdbms/orcl/orcl/incident/incdir_122458/orcl_ora_14937_i122458.trc Errors in file /u01/app/oracle/diag/rdbms/orcl/orcl/trace/orcl_ora_14937.trc (incident=122459): ……………… Tue Sep 24 14:32:16 2024 Errors in file /u01/app/oracle/diag/rdbms/orcl/orcl/incident/incdir_124802/orcl_ora_14937_i124802.trc: ORA-00603: ORACLE server session terminated by fatal error ORA-00600: internal error code, arguments: [2662], [0], [119484866], [0], [119484868], [16777344]…… ORA-00600: internal error code, arguments: [2662], [0], [119484865], [0], [119484868], [16777344]…… ORA-01092: ORACLE instance terminated. Disconnection forced ORA-00600: internal error code, arguments: [2662], [0], [119484861], [0], [119484868], [16777344]……
客户的自行恢复到此为止,没有成功,这里客户的恢复没有犯原则性错误(破坏文件的resetlogs 信息),同时也没有解决两个ORA-600错误
1. 在offline部分文件的情况下,打开数据库(没有使用resetlogs,避免了进一步破坏offline文件的resetlogs 信息),但是数据库报ORA-600 4193错误没有打开库成功
2. 后面强制拉库之前重建了ctl文件,避免了offline数据文件在resetlogs之后导致文件头resetlogs 信息和其他文件不一致的可能(因为重建ctl,offline的文件自动onlinne)
3. 最初offline数据文件,启动库报ORA-600 4193故障没有解决,这个故障一般是undo异常导致,这个故障大概率在后面强制拉库open过程中还可能遇到
4. 强制拉库过程中遭遇ORA-600 2662问题,需要修改scn,如果这个问题不解决,数据库无法open成功
存储宕机导致Oracle异常故障处理
存储突然掉线,导致数据库crash,报大量ORA-00206 ORA-00202 ORA-15081以及Linux-x86_64 Error: 5: Input/output error之类的错误
Sun Jul 21 20:00:11 2024 Thread 1 advanced to log sequence 1594398 (LGWR switch) Current log# 5 seq# 1594398 mem# 0: +DATA/xff/onlinelog/group_5.412.906718739 Sun Jul 21 20:53:17 2024 WARNING: Write Failed. group:2 disk:0 AU:506916 offset:49152 size:16384 Sun Jul 21 20:53:17 2024 WARNING: Read Failed. group:2 disk:2 AU:506931 offset:49152 size:16384 WARNING: failed to read mirror side 1 of virtual extent 4 logical extent 0 of file 415 in group [2.34109396] from disk ORACLE_DATA_0002 allocation unit 506931 reason error; if possible, will try another mirror side Errors in file /users/oracle/app/db/diag/rdbms/xff/xff1/trace/xff1_ckpt_42142.trc: ORA-15080: 与磁盘的同步 I/O 操作失败 ORA-27061: 异步 I/O 等待失败 Linux-x86_64 Error: 5: Input/output error Additional information: -1 Additional information: 16384 WARNING: failed to write mirror side 1 of virtual extent 0 logical extent 0 of file 415 in group 2 on disk 0 allocation unit 506916 Errors in file /users/oracle/app/db/diag/rdbms/xff/xff1/trace/xff1_ckpt_42142.trc: ORA-00206: 写入控制文件时出错 (块 3, # 块 1) ORA-00202: 控制文件: ''+DATA/xff/controlfile/current.415.906718737'' ORA-15081: 无法将 I/O 操作提交到磁盘 ORA-15081: 无法将 I/O 操作提交到磁盘 Errors in file /users/oracle/app/db/diag/rdbms/xff/xff1/trace/xff1_ckpt_42142.trc: ORA-00221: 写入控制文件时出错 ORA-00206: 写入控制文件时出错 (块 3, # 块 1) ORA-00202: 控制文件: ''+DATA/xff/controlfile/current.415.906718737'' ORA-15081: 无法将 I/O 操作提交到磁盘 ORA-15081: 无法将 I/O 操作提交到磁盘 CKPT (ospid: 42142): terminating the instance due to error 221 Errors in file /users/oracle/app/db/diag/rdbms/xff/xff1/trace/xff1_lmon_42087.trc: ORA-00202: 控制文件: ''+DATA/xff/controlfile/current.415.906718737'' ORA-15081: 无法将 I/O 操作提交到磁盘 ORA-27072: 文件 I/O 错误 Linux-x86_64 Error: 5: Input/output error Additional information: 4 Additional information: 1038194784 Additional information: -1 Sun Jul 21 20:53:19 2024 ORA-1092 : opitsk aborting process Sun Jul 21 20:53:24 2024 ORA-1092 : opitsk aborting process Sun Jul 21 20:53:24 2024 License high water mark = 59 Sun Jul 21 20:53:28 2024 Instance terminated by CKPT, pid = 42142 USER (ospid: 64660): terminating the instance Instance terminated by USER, pid = 64660
存储恢复之后启动数据库报ORA-600 2131错误
Mon Jul 22 09:10:04 2024 ALTER DATABASE MOUNT This instance was first to mount Mon Jul 22 09:10:04 2024 Sweep [inc][490008]: completed Sweep [inc2][490008]: completed NOTE: Loaded library: System SUCCESS: diskgroup ORACLE_DATA was mounted NOTE: dependency between database rac and diskgroup resource ora.ORACLE_DATA.dg is established Errors in file /users/oracle/app/db/diag/rdbms/xff/xff1/trace/xff1_ora_14301.trc (incident=492409): ORA-00600: ??????, ??: [2131], [33], [32], [], [], [], [], [], [], [], [], [] Incident details in: /users/oracle/app/db/diag/rdbms/xff/xff1/incident/incdir_492409/xff1_ora_14301_i492409.trc Use ADRCI or Support Workbench to package the incident. See Note 411.1 at My Oracle Support for error and packaging details. ORA-600 signalled during: ALTER DATABASE MOUNT...
客户尝试重建ctl进行恢复,结果由于分析不正确,导致在重建ctl的时候,遗漏了3个数据文件,并且在屏蔽一致性的情况下,强制resetlogs操作,结果数据库没有被正常打开,而是报ORA-600 2662错误
alter database open resetlogs RESETLOGS is being done without consistancy checks. This may result in a corrupted database. The database should be recreated. RESETLOGS after incomplete recovery UNTIL CHANGE 9965567206652 Clearing online redo logfile 1 +DATA/xff/onlinelog/group_1.414.906718739 Clearing online log 1 of thread 1 sequence number 0 Clearing online redo logfile 1 complete Clearing online redo logfile 2 +DATA/xff/onlinelog/group_2.413.906718739 Clearing online log 2 of thread 1 sequence number 0 Clearing online redo logfile 2 complete Clearing online redo logfile 5 +DATA/xff/onlinelog/group_5.412.906718739 Clearing online log 5 of thread 1 sequence number 0 Clearing online redo logfile 5 complete Expanded controlfile section 2 from 1 to 63 records The number of logical blocks in section 2 remains the same Expanded controlfile section 1 from 4 to 66 records Requested to grow by 62 records; added 32 blocks of records Expanded controlfile section 30 from 1 to 63 records The number of logical blocks in section 30 remains the same Expanded controlfile section 29 from 1 to 63 records The number of logical blocks in section 29 remains the same Control file has been expanded to support 63 threads Mon Jul 22 23:04:07 2024 Redo thread 2 enabled by open resetlogs or standby activation Online log +DATA/xff/onlinelog/group_1.414.906718739: Thread 1 Group 1 was previously cleared Online log +DATA/xff/onlinelog/group_2.413.906718739: Thread 1 Group 2 was previously cleared Online log +DATA/xff/onlinelog/group_3.501.1175036643: Thread 2 Group 3 was previously cleared Online log +DATA/xff/onlinelog/group_4.502.1175036645: Thread 2 Group 4 was previously cleared Online log +DATA/xff/onlinelog/group_5.412.906718739: Thread 1 Group 5 was previously cleared Mon Jul 22 23:04:08 2024 Setting recovery target incarnation to 2 Initializing SCN for created control file Database SCN compatibility initialized to 3 Warning - High Database SCN: Current SCN value is 9965567206655, threshold SCN value is 0 If you have not previously reported this warning on this database, please notify Oracle Support so that additional diagnosis can be performed. Mon Jul 22 23:04:09 2024 Assigning activation ID 2763017873 (0xa4b04e91) Thread 1 opened at log sequence 1 Current log# 1 seq# 1 mem# 0: +DATA/xff/onlinelog/group_1.414.906718739 Successful open of redo thread 1 MTTR advisory is disabled because FAST_START_MTTR_TARGET is not set Mon Jul 22 23:04:10 2024 SMON: enabling cache recovery Errors in file /users/oracle/app/db/diag/rdbms/xff/xff1/trace/xff1_ora_64210.trc (incident=624374): ORA-00600: 内部错误代码, 参数: [2662], [2320], [1243079939], [2320], [1243211805], [12583040], [], [], [], [], [], [] Incident details in: /users/oracle/app/db/diag/rdbms/xff/xff1/incident/incdir_624374/xff1_ora_64210_i624374.trc Use ADRCI or Support Workbench to package the incident. See Note 411.1 at My Oracle Support for error and packaging details. Errors in file /users/oracle/app/db/diag/rdbms/xff/xff1/trace/xff1_ora_64210.trc: ORA-00600: 内部错误代码, 参数: [2662], [2320], [1243079939], [2320], [1243211805], [12583040], [], [], [], [], [], [] Errors in file /users/oracle/app/db/diag/rdbms/xff/xff1/trace/xff1_ora_64210.trc: ORA-00600: 内部错误代码, 参数: [2662], [2320], [1243079939], [2320], [1243211805], [12583040], [], [], [], [], [], [] Error 600 happened during db open, shutting down database USER (ospid: 64210): terminating the instance due to error 600 Instance terminated by USER, pid = 64210 ORA-1092 signalled during: alter database open resetlogs...
操作到这里,后续问题就比较麻烦了,因为在asm磁盘组中数据文件重建ctl的时候遗漏3个并且还被resetlogs操作过,导致这三个文件的resetlogs scn和其他数据文件不一致,对于这个问题,解决办法通过Oracle Recovery Tools工具或者bbed修改相关resetlogs scn,然后重建ctl
SQL> @rectl.sql Control file created. SQL> RECOVER DATABASE; Media recovery complete
然后解决之前数据库启动报ORA-600 2662问题,通过修改数据库scn进行解决,可以使用Patch_SCN工具进行快速解决,然后open数据库成功
SQL> ALTER DATABASE OPEN; Database altered.
但是查看alert日志数据库报大量ORA-600 4194、ORA-01595和Exception [type: SIGSEGV, Address not mapped to object] [ADDR:0xC21D511] [PC:0x97F4EFA, kgegpa()+40]之类错误
Wed Jul 24 15:24:21 2024 alter database open Beginning crash recovery of 1 threads parallel recovery started with 32 processes Started redo scan Completed redo scan read 0 KB redo, 0 data blocks need recovery ………… Database Characterset is ZHS16GBK No Resource Manager plan active Errors in file /users/oracle/app/db/diag/rdbms/xff/xff1/trace/xff1_smon_40279.trc (incident=777938): ORA-00600: 内部错误代码, 参数: [4194], [], [], [], [], [], [], [], [], [], [], [] Use ADRCI or Support Workbench to package the incident. See Note 411.1 at My Oracle Support for error and packaging details. replication_dependency_tracking turned off (no async multimaster replication found) Starting background process QMNC Wed Jul 24 15:24:40 2024 QMNC started with pid=79, OS id=54632 Block recovery from logseq 2, block 74 to scn 9965587206835 Recovery of Online Redo Log: Thread 1 Group 2 Seq 2 Reading mem 0 Mem# 0: +DATA/xff/onlinelog/redo02 LOGSTDBY: Validating controlfile with logical metadata Wed Jul 24 15:24:40 2024 Block recovery stopped at EOT rba 2.82.16 Block recovery completed at rba 2.82.16, scn 2320.1263080114 Block recovery from logseq 2, block 74 to scn 9965587206833 Recovery of Online Redo Log: Thread 1 Group 2 Seq 2 Reading mem 0 Mem# 0: +DATA/xff/onlinelog/redo02 Block recovery completed at rba 2.82.16, scn 2320.1263080114 Errors in file /users/oracle/app/db/diag/rdbms/xff/xff1/trace/xff1_smon_40279.trc: ORA-01595: 释放区 (4) 回退段 (20) 时出错 ORA-00600: 内部错误代码, 参数: [4194], [], [], [], [], [], [], [], [], [], [], [] LOGSTDBY: Validation complete Wed Jul 24 15:24:41 2024 Sweep [inc][777938]: completed Sweep [inc2][777938]: completed Wed Jul 24 15:24:41 2024 Errors in file /users/oracle/app/db/diag/rdbms/xff/xff1/trace/xff1_q001_54657.trc (incident=778362): ORA-00600: 内部错误代码, 参数: [4194], [], [], [], [], [], [], [], [], [], [], [] Use ADRCI or Support Workbench to package the incident. See Note 411.1 at My Oracle Support for error and packaging details. Starting background process SMCO Wed Jul 24 15:24:42 2024 SMCO started with pid=83, OS id=54691 Block recovery from logseq 2, block 74 to scn 9965587206835 Recovery of Online Redo Log: Thread 1 Group 2 Seq 2 Reading mem 0 Mem# 0: +DATA/xff/onlinelog/redo02 Block recovery completed at rba 2.82.16, scn 2320.1263080118 Block recovery from logseq 2, block 74 to scn 9965587206838 Recovery of Online Redo Log: Thread 1 Group 2 Seq 2 Reading mem 0 Mem# 0: +DATA/xff/onlinelog/redo02 Block recovery completed at rba 2.83.16, scn 2320.1263080119 Error 600 in kwqmnpartition(), aborting txn Errors in file /users/oracle/app/db/diag/rdbms/xff/xff1/trace/xff1_q001_54657.trc (incident=778363): ORA-25319: 队列表重新分区已中止 Completed: alter database open Block recovery from logseq 2, block 74 to scn 9965587206835 Recovery of Online Redo Log: Thread 1 Group 2 Seq 2 Reading mem 0 Mem# 0: +DATA/rac/onlinelog/redo02 Block recovery completed at rba 2.82.16, scn 2320.1263080118 Block recovery from logseq 2, block 74 to scn 9965587207538 Recovery of Online Redo Log: Thread 1 Group 2 Seq 2 Reading mem 0 Mem# 0: +DATA/rac/onlinelog/redo02 Block recovery completed at rba 2.1097.16, scn 2320.1263080819 Errors in file /users/oracle/app/db/diag/rdbms/rac/rac1/trace/rac1_cjq0_55657.trc (incident=778427): ORA-00600: 内部错误代码, 参数: [600], [ORA-00600: 内部错误代码, 参数: [4194], [], [], [], [], [], [], [], [], [], [], []], [], [], [], [], [], [], [], [], [], [] Incident details in: /users/oracle/app/db/diag/rdbms/xff/xff1/incident/incdir_778427/xff1_cjq0_55657_i778427.trc Exception [type:SIGSEGV, Address not mapped to object][ADDR:0xC21D511][PC:0x97F4EFA, kgegpa()+40][flags: 0x0, count: 1] Exception [type:SIGSEGV, Address not mapped to object][ADDR:0xC21D511][PC:0x97F396E, kgebse()+776][flags: 0x2, count: 2] Exception [type:SIGSEGV, Address not mapped to object][ADDR:0xC21D511][PC:0x97F396E, kgebse()+776][flags: 0x2, count: 2]
从报错分析是由于undo异常导致,处理异常undo回滚段之后,数据库open正常,安排逻辑迁移数据,完成本次恢复
发表在 Oracle备份恢复
标签为 kgegpa, ORA-00206 ORA-00202 ORA-15081, ORA-600 2131, ORA-600 2662, ORA-600 4194, 存储宕机oracle处理
评论关闭