11.2開啟資料庫碰到ORA-214錯誤

yangtingkun發表於2011-02-17

客戶的測試伺服器在沒有關閉資料庫的情況下,重啟了系統,出現了這個錯誤。

 

 

資料庫版本是11.2.0.2 for Linux 6 x86-64

由於資料庫在開啟使用的過程中,作業系統上執行了reboot操作,導致了ORA-214的錯誤,詳細的錯誤資訊為:

SQL> startup
ORACLE instance started.

Total System Global Area 4275781632 bytes
Fixed Size 2233336 bytes
Variable Size 3087010824 bytes
Database Buffers 1174405120 bytes
Redo Buffers 12132352 bytes
ORA-00214: control file '/opt/oracle/fast_recovery_area/MOBILEDB/control02.ctl' version 482 inconsistent with file '/data1/oradata/mobiledb/MOBILEDB/control01.ctl' version 451

不過我並沒有親眼看到這個錯誤,這個錯誤資訊是客戶發過來的,當我登入伺服器執行啟動命令打算重現問題時:

[oracle@Oracle111 ~]$ sqlplus / as sysdba

SQL*Plus: Release 11.2.0.2.0 Production on Thu Feb 17 14:27:25 2011

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

Connected to an idle instance.

SQL> startup
ORACLE instance started.

Total System Global Area 4275781632 bytes
Fixed Size                  2233336 bytes
Variable Size            3087010824 bytes
Database Buffers         1174405120 bytes
Redo Buffers               12132352 bytes
Database mounted.
Database opened.
SQL> show parameter control_file

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
control_file_record_keep_time        integer     7
control_files                        string      /data1/oradata/mobiledb/MOBILE
                                                 DB/control01.ctl, /opt/oracle/
                                                 fast_recovery_area/MOBILEDB/co
                                                 ntrol02.ctl

詢問客戶,客戶說沒有進行過恢復操作,檢查alert檔案:

Starting ORACLE instance (normal)
LICENSE_MAX_SESSION = 0
LICENSE_SESSIONS_WARNING = 0
Picked latch-free SCN scheme 3
Using LOG_ARCHIVE_DEST_1 parameter default value as USE_DB_RECOVERY_FILE_DEST
Autotune of undo retention is turned on.
IMODE=BR
ILAT =28
LICENSE_MAX_USERS = 0
SYS auditing is disabled
Starting up:
Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options.
Using parameter settings in server-side spfile /opt/oracle/product/11.2.0/db/dbs/spfilemobiledb.ora
System parameters with non-default values:
  processes                = 150
  sga_target               = 1536M
  control_files            = "/data1/oradata/mobiledb/MOBILEDB/control01.ctl"
  control_files            = "/opt/oracle/fast_recovery_area/MOBILEDB/control02.ctl"
  db_block_size            = 8192
  compatible               = "11.2.0.0.0"
  db_recovery_file_dest    = "/opt/oracle/fast_recovery_area"
  db_recovery_file_dest_size= 4977M
  undo_tablespace          = "UNDOTBS1"
  remote_login_passwordfile= "EXCLUSIVE"
  db_domain                = ""
  dispatchers              = "(PROTOCOL=TCP) (SERVICE=mobiledbXDB)"
  audit_file_dest          = "/opt/oracle/admin/MOBILEDB/adump"
  audit_trail              = "DB"
  db_name                  = "MOBILEDB"
  open_cursors             = 300
  pga_aggregate_target     = 1657M
  diagnostic_dest          = "/opt/oracle"
Thu Feb 17 11:47:07 2011
PMON started with pid=2, OS id=3601
Thu Feb 17 11:47:07 2011
.
.
.
MMON started with pid=16, OS id=3631
Thu Feb 17 11:47:08 2011
MMNL started with pid=17, OS id=3633
starting up 1 dispatcher(s) for network address '(ADDRESS=(PARTIAL=YES)(PROTOCOL=TCP))'...
starting up 1 shared server(s) ...
ORACLE_BASE from environment = /opt/oracle
Thu Feb 17 11:47:08 2011
ALTER DATABASE   MOUNT
Successful mount of redo thread 1, with mount id 3104105148
Database mounted in Exclusive Mode
Lost write protection disabled
Completed: ALTER DATABASE   MOUNT
Thu Feb 17 11:47:12 2011
ALTER DATABASE OPEN
Thread 1 opened at log sequence 69
  Current log# 3 seq# 69 mem# 0: /data1/oradata/mobiledb/MOBILEDB/redo03.log
Successful open of redo thread 1
MTTR advisory is disabled because FAST_START_MTTR_TARGET is not set
SMON: enabling cache recovery
[3644] Successfully onlined Undo Tablespace 2.
Undo initialization finished serial:0 start:4891584 end:4891624 diff:40 (0 seconds)
Verifying file header compatibility for 11g tablespace encryption..
Verifying 11g file header compatibility for tablespace encryption completed
SMON: enabling tx recovery
Database Characterset is ZHS16GBK
No Resource Manager plan active
replication_dependency_tracking turned off (no async multimaster replication found)
Starting background process QMNC
Thu Feb 17 11:47:13 2011
QMNC started with pid=21, OS id=3648
Completed: ALTER DATABASE OPEN
Thu Feb 17 11:47:13 2011
db_recovery_file_dest_size of 4977 MB is 0.00% used. This is a
user-specified limit on the amount of space that will be used by this
database for recovery-related files, and does not reflect the amount of
space available in the underlying filesystem or ASM diskgroup.
Starting background process CJQ0
Thu Feb 17 11:47:13 2011
CJQ0 started with pid=22, OS id=3662
Thu Feb 17 11:57:13 2011
Starting background process SMCO
Thu Feb 17 11:57:13 2011
SMCO started with pid=20, OS id=3698
Thu Feb 17 13:32:40 2011
ALTER SYSTEM SET sga_max_size='4096M' SCOPE=SPFILE;
Thu Feb 17 13:41:07 2011
ALTER SYSTEM SET processes=1000 SCOPE=SPFILE;
Thu Feb 17 14:16:37 2011
Starting ORACLE instance (normal)
LICENSE_MAX_SESSION = 0
LICENSE_SESSIONS_WARNING = 0
Picked latch-free SCN scheme 3
Using LOG_ARCHIVE_DEST_1 parameter default value as USE_DB_RECOVERY_FILE_DEST
Autotune of undo retention is turned on.
IMODE=BR
ILAT =168
LICENSE_MAX_USERS = 0
SYS auditing is disabled
Starting up:
Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options.
Using parameter settings in server-side spfile /opt/oracle/product/11.2.0/db/dbs/spfilemobiledb.ora
System parameters with non-default values:
  processes                = 1000
  sga_max_size             = 4G
  sga_target               = 1536M
  control_files            = "/data1/oradata/mobiledb/MOBILEDB/control01.ctl"
  control_files            = "/opt/oracle/fast_recovery_area/MOBILEDB/control02.ctl"
  db_block_size            = 8192
  compatible               = "11.2.0.0.0"
  db_recovery_file_dest    = "/opt/oracle/fast_recovery_area"
  db_recovery_file_dest_size= 4977M
  undo_tablespace          = "UNDOTBS1"
  remote_login_passwordfile= "EXCLUSIVE"
  db_domain                = ""
  dispatchers              = "(PROTOCOL=TCP) (SERVICE=mobiledbXDB)"
  audit_file_dest          = "/opt/oracle/admin/MOBILEDB/adump"
  audit_trail              = "DB"
  db_name                  = "MOBILEDB"
  open_cursors             = 300
  pga_aggregate_target     = 1657M
  diagnostic_dest          = "/opt/oracle"
Thu Feb 17 14:16:38 2011
PMON started with pid=2, OS id=2678
Thu Feb 17 14:16:38 2011
PSP0 started with pid=3, OS id=2680
.
.
.
MMNL started with pid=17, OS id=2710
starting up 1 shared server(s) ...
ORACLE_BASE from environment = /opt/oracle
Thu Feb 17 14:16:40 2011
ALTER DATABASE   MOUNT
ORA-214 signalled during: ALTER DATABASE   MOUNT...
Thu Feb 17 14:16:40 2011
Checker run found 2 new persistent data failures
Thu Feb 17 14:17:24 2011
alter database open
ORA-1507 signalled during: alter database open...
Thu Feb 17 14:17:56 2011
alter database open
ORA-1507 signalled during: alter database open...
Thu Feb 17 14:17:57 2011
Shutting down instance (immediate)
Shutting down instance: further logons disabled
Stopping background process MMNL
Stopping background process MMON
License high water mark = 2
All dispatchers and shared servers shutdown
ALTER DATABASE CLOSE NORMAL
ORA-1507 signalled during: ALTER DATABASE CLOSE NORMAL...
ARCH: Archival disabled due to shutdown: 1089
Shutting down archive processes
Archiving is disabled
Thu Feb 17 14:18:02 2011
Stopping background process VKTM
ARCH: Archival disabled due to shutdown: 1089
Shutting down archive processes
Archiving is disabled
Thu Feb 17 14:18:04 2011
Instance shutdown complete
Thu Feb 17 14:18:12 2011
Starting ORACLE instance (normal)
LICENSE_MAX_SESSION = 0
LICENSE_SESSIONS_WARNING = 0
Picked latch-free SCN scheme 3
Using LOG_ARCHIVE_DEST_1 parameter default value as USE_DB_RECOVERY_FILE_DEST
Autotune of undo retention is turned on.
IMODE=BR
ILAT =168
LICENSE_MAX_USERS = 0
SYS auditing is disabled
Starting up:
Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options.
Using parameter settings in server-side spfile /opt/oracle/product/11.2.0/db/dbs/spfilemobiledb.ora
System parameters with non-default values:
  processes                = 1000
  sga_max_size             = 4G
  sga_target               = 1536M
  control_files            = "/data1/oradata/mobiledb/MOBILEDB/control01.ctl"
  control_files            = "/opt/oracle/fast_recovery_area/MOBILEDB/control02.ctl"
  db_block_size            = 8192
  compatible               = "11.2.0.0.0"
  db_recovery_file_dest    = "/opt/oracle/fast_recovery_area"
  db_recovery_file_dest_size= 4977M
  undo_tablespace          = "UNDOTBS1"
  remote_login_passwordfile= "EXCLUSIVE"
  db_domain                = ""
  dispatchers              = "(PROTOCOL=TCP) (SERVICE=mobiledbXDB)"
  audit_file_dest          = "/opt/oracle/admin/MOBILEDB/adump"
  audit_trail              = "DB"
  db_name                  = "MOBILEDB"
  open_cursors             = 300
  pga_aggregate_target     = 1657M
  diagnostic_dest          = "/opt/oracle"
Thu Feb 17 14:18:12 2011
PMON started with pid=2, OS id=2756
Thu Feb 17 14:18:12 2011
PSP0 started with pid=3, OS id=2758
Thu Feb 17 14:18:13 2011
.
.
.
Thu Feb 17 14:18:14 2011
MMNL started with pid=17, OS id=2788
starting up 1 shared server(s) ...
ORACLE_BASE from environment = /opt/oracle
Thu Feb 17 14:18:14 2011
ALTER DATABASE   MOUNT
ORA-214 signalled during: ALTER DATABASE   MOUNT...
Thu Feb 17 14:19:26 2011
Starting ORACLE instance (normal)
Thu Feb 17 14:20:35 2011
alter database open
ORA-1507 signalled during: alter database open...
alter database mount
ORA-214 signalled during: alter database mount...
Thu Feb 17 14:21:20 2011
Shutting down instance (immediate)
Shutting down instance: further logons disabled
Stopping background process MMNL
Stopping background process MMON
License high water mark = 2
All dispatchers and shared servers shutdown
ALTER DATABASE CLOSE NORMAL
ORA-1507 signalled during: ALTER DATABASE CLOSE NORMAL...
ARCH: Archival disabled due to shutdown: 1089
Shutting down archive processes
Archiving is disabled
ARCH: Archival disabled due to shutdown: 1089
Thu Feb 17 14:21:23 2011
Stopping background process VKTMShutting down archive processes

Archiving is disabled
Thu Feb 17 14:21:25 2011
Instance shutdown complete
Thu Feb 17 14:27:33 2011
Starting ORACLE instance (normal)
LICENSE_MAX_SESSION = 0
LICENSE_SESSIONS_WARNING = 0
Picked latch-free SCN scheme 3
Using LOG_ARCHIVE_DEST_1 parameter default value as USE_DB_RECOVERY_FILE_DEST
Autotune of undo retention is turned on.
IMODE=BR
ILAT =168
LICENSE_MAX_USERS = 0
SYS auditing is disabled
Starting up:
Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options.
Using parameter settings in server-side spfile /opt/oracle/product/11.2.0/db/dbs/spfilemobiledb.ora
System parameters with non-default values:
  processes                = 1000
  sga_max_size             = 4G
  sga_target               = 1536M
  control_files            = "/data1/oradata/mobiledb/MOBILEDB/control01.ctl"
  control_files            = "/opt/oracle/fast_recovery_area/MOBILEDB/control02.ctl"
  db_block_size            = 8192
  compatible               = "11.2.0.0.0"
  db_recovery_file_dest    = "/opt/oracle/fast_recovery_area"
  db_recovery_file_dest_size= 4977M
  undo_tablespace          = "UNDOTBS1"
  remote_login_passwordfile= "EXCLUSIVE"
  db_domain                = ""
  dispatchers              = "(PROTOCOL=TCP) (SERVICE=mobiledbXDB)"
  audit_file_dest          = "/opt/oracle/admin/MOBILEDB/adump"
  audit_trail              = "DB"
  db_name                  = "MOBILEDB"
  open_cursors             = 300
  pga_aggregate_target     = 1657M
  diagnostic_dest          = "/opt/oracle"
Thu Feb 17 14:27:34 2011
PMON started with pid=2, OS id=2962
Thu Feb 17 14:27:34 2011
PSP0 started with pid=3, OS id=2964
Thu Feb 17 14:27:35 2011
.
.
.
MMNL started with pid=17, OS id=2994
starting up 1 shared server(s) ...
ORACLE_BASE from environment = /opt/oracle
Thu Feb 17 14:27:35 2011
ALTER DATABASE   MOUNT
Successful mount of redo thread 1, with mount id 3104082775
Database mounted in Exclusive Mode
Lost write protection disabled
Completed: ALTER DATABASE   MOUNT
Thu Feb 17 14:27:39 2011
ALTER DATABASE OPEN
Beginning crash recovery of 1 threads
 parallel recovery started with 15 processes
Started redo scan
Completed redo scan
 read 29 KB redo, 31 data blocks need recovery
Started redo application at
 Thread 1: logseq 69, block 87640
Recovery of Online Redo Log: Thread 1 Group 3 Seq 69 Reading mem 0
  Mem# 0: /data1/oradata/mobiledb/MOBILEDB/redo03.log
Completed redo application of 0.02MB
Completed crash recovery at
 Thread 1: logseq 69, block 87699, scn 1018311
 31 data blocks read, 31 data blocks written, 29 redo k-bytes read
Thread 1 advanced to log sequence 70 (thread open)
Thread 1 opened at log sequence 70
  Current log# 1 seq# 70 mem# 0: /data1/oradata/mobiledb/MOBILEDB/redo01.log
Successful open of redo thread 1
MTTR advisory is disabled because FAST_START_MTTR_TARGET is not set
SMON: enabling cache recovery
[3004] Successfully onlined Undo Tablespace 2.
Undo initialization finished serial:0 start:907194 end:907484 diff:290 (2 seconds)
Verifying file header compatibility for 11g tablespace encryption..
Verifying 11g file header compatibility for tablespace encryption completed
SMON: enabling tx recovery
Database Characterset is ZHS16GBK
No Resource Manager plan active
replication_dependency_tracking turned off (no async multimaster replication found)
Starting background process QMNC
Thu Feb 17 14:27:42 2011
QMNC started with pid=36, OS id=3038
Completed: ALTER DATABASE OPEN

只是重啟了兩次,而沒有人去修改控制檔案,難道Oracle就自愈了這個問題。後來詢問客戶得知,當時正在向作業系統上掛載新的目錄,而控制檔案control01.ctl就處於被掛載的目錄下,而客戶執行的reboot也是為了驗證目錄在重啟後能否自動掛載。

觀察控制檔案的不一致資訊發現,control01.ctl比非掛載點上的control02.ctl的版本低,很可能是由於掛載重現了問題,而導致這個檔案的需要在作業系統級別恢復,當最後成功掛載後,這個檔案的狀態也恢復了正常,因此錯誤也就消失了。

 

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/4227/viewspace-687470/,如需轉載,請註明出處,否則將追究法律責任。

相關文章