ORA-01102: cannot mount database in EXCLUSIVE mode
2017-01-04 18:24
603 查看
ORA-01102:cannotmountdatabaseinEXCLUSIVEmode
安装完ORACEL10g数据库后,启动数据库时遇到ORA-01102:cannotmountdatabaseinEXCLUSIVEmode[code] [code][oracle@DB-Server~]$sqlplus/assysdba
SQL*Plus:Release10.2.0.1.0-ProductiononThuApr1013:53:082014
Copyright(c)1982,2005,Oracle.Allrightsreserved.
Connectedtoanidleinstance.
SQL>startup
ORACLEinstancestarted.
TotalSystemGlobalArea5033164800bytes
FixedSize2027672bytes
VariableSize905973608bytes
DatabaseBuffers4110417920bytes
RedoBuffers14745600bytes
ORA-01102:cannotmountdatabaseinEXCLUSIVEmode
[/code]
[/code]
查看告警日志文件,发现有ORA-09968:unabletolockfile和Linux-x86_64Error:11:Resourcetemporarilyunavailable等错误
[code]
[code][oracle@DB-Serverbdump]$tail-20falert_epps.log
SMONstartedwithpid=8,OSid=24482
RECOstartedwithpid=9,OSid=24484
CJQ0startedwithpid=10,OSid=24486
MMONstartedwithpid=11,OSid=24488
ThuApr1013:53:422014
startingup1dispatcher(s)fornetworkaddress'(ADDRESS=(PARTIAL=YES)(PROTOCOL=TCP))'...
MMNLstartedwithpid=12,OSid=24490
ThuApr1013:53:422014
startingup1sharedserver(s)...
ThuApr1013:53:422014
ALTERDATABASEMOUNT
ThuApr1013:53:422014
sculkget:failedtolock/u01/app/oracle//product/10.2.0/db_1/dbs/lkEPPSexclusive
sculkget:lockheldbyPID:20337
ThuApr1013:53:422014
ORA-09968:unabletolockfile
Linux-x86_64Error:11:Resourcetemporarilyunavailable
Additionalinformation:20337
ThuApr1013:53:422014
ORA-1102signalledduring:ALTERDATABASEMOUNT...
[/code]
[/code]
'
第一次遇到这种情况,于是网上搜索了一下资料,找到一篇相关文章
a、Oracle的共享内存段或信号量没有被释放;
b、Oracle的后台进程(如SMON、PMON、DBWn等)没有被关闭;
c、用于锁内存的文件lk<sid>和sgadef<sid>.dbf文件没有被删除。
看了文章前面一部分。便武断的觉得应该是第三者情况(由于告警日志中出现了相关信息):“用于锁内存的文件lk<sid>和sgadef<sid>.dbf文件没有被删除”。于是动手操作(太心急,这毛病老是难以改变),关闭数据库实例,删除/u01/app/oracle/product/10.2.0/db_1/dbs/lkEPPS文件后,重新启动数据库。结果作者的经历又在我身上重演了一次。
启动时候报ORA-00205错误
[code]
[code]SQL>shutdownimmediate;
ORA-01507:databasenotmounted
ORACLEinstanceshutdown.
SQL>startup
ORACLEinstancestarted.
TotalSystemGlobalArea5033164800bytes
FixedSize2027672bytes
VariableSize905973608bytes
DatabaseBuffers4110417920bytes
RedoBuffers14745600bytes
ORA-00205:errorinidentifyingcontrolfile,checkalertlogformoreinfo
[/code]
[/code]
查看告警日志,有如下错误信息:
[code]
[code]RECOstartedwithpid=9,OSid=24887
CJQ0startedwithpid=10,OSid=24889
MMONstartedwithpid=11,OSid=24891
ThuApr1014:04:052014
startingup1dispatcher(s)fornetworkaddress'(ADDRESS=(PARTIAL=YES)(PROTOCOL=TCP))'...
MMNLstartedwithpid=12,OSid=24894
ThuApr1014:04:062014
startingup1sharedserver(s)...
ThuApr1014:04:062014
ALTERDATABASEMOUNT
ThuApr1014:04:062014
ORA-00202:controlfile:'/u01/app/oracle/oradata/epps/control01.ctl'
ORA-27086:unabletolockfile-alreadyinuse
Linux-x86_64Error:11:Resourcetemporarilyunavailable
Additionalinformation:8
Additionalinformation:20341
ThuApr1014:04:092014
ORA-205signalledduring:ALTERDATABASEMOUNT...
[/code]
[/code]
于是索性静下心来多了解一下这个问题,在网上查看了大量关于ORA-01102的文章。这篇博客
ProblemDescription:
====================
Youaretryingtostartupthedatabaseandyoureceivethefollowingerror:
ORA-01102:cannotmountdatabaseinEXCLUSIVEmode
Cause:Someotherinstancehasthedatabasemountedexclusiveorshared.
Action:Shutdownotherinstanceormountinacompatiblemode.
ProblemExplanation:
====================
AdatabaseisstartedinEXCLUSIVEmodebydefault.Therefore,theORA-01102errorismisleadingandmayhaveoccurredduetooneofthefollowingreasons:
-thereisstillan"sgadef<sid>.dbf"fileinthe"ORACLE_HOME/dbs"directory
-theprocessesforOracle(pmon,smon,lgwranddbwr)stillexist
-sharedmemorysegmentsandsemaphoresstillexisteventhoughthe
databasehasbeenshutdown
-thereisa"ORACLE_HOME/dbs/lk<sid>"file
SearchWords:
=============
ORA-1102,crash,immediate,abort,fail,fails,migration
SolutionDescription:
=====================
Verifythatthedatabasewasshutdowncleanlybydoingthefollowing:
1.Verifythatthereisnota"sgadef<sid>.dbf"fileinthedirectory"ORACLE_HOME/dbs".
%ls$ORACLE_HOME/dbs/sgadef<sid>.dbfIfthisfiledoesexist,removeit.
%rm$ORACLE_HOME/dbs/sgadef<sid>.dbf
2.Verifythattherearenobackgroundprocessesownedby"oracle"
%ps-ef|grepora_|grep$ORACLE_SID
Ifbackgroundprocessesexist,removethembyusingtheUnix
command"kill".Forexample:
%kill-9<rocess_ID_Number>
3.Verifythatnosharedmemorysegmentsandsemaphoresthatareownedby"oracle"stillexist
%ipcs-b
Iftherearesharedmemorysegmentsandsemaphoresownedby"oracle",removethesharedmemorysegments
%ipcrm-m<Shared_Memory_ID_Number>
andremovethesemaphores
%ipcrm-s<Semaphore_ID_Number>
NOTE:Theexampleshownaboveassumesthatyouonlyhaveone
databaseonthismachine.Ifyouhavemorethanone
database,youwillneedtoshutdownallotherdatabases
beforeproceedingwithStep4.
4.Verifythatthe"$ORACLE_HOME/dbs/lk<sid>"filedoesnotexist
5.Startuptheinstance
SolutionExplanation:
=====================
The"lk<sid>"and"sgadef<sid>.dbf"filesareusedforlockingsharedmemory.Itseemsthateventhoughnomemoryisallocated,Oraclethinksmemoryisstilllocked.Byremovingthe"sgadef"and"lk"filesyouremoveanyknowledgeoraclehasofsharedmemorythatisinuse.Nowthedatabasecanstart.
参考资料:
相关文章推荐
- ORA-01102: cannot mount database in EXCLUSIVE mode
- ORA-01102 cannot mount database in EXCLUSIVE mode
- ORA-01102: cannot mount database in EXCLUSIVE mode - Linux Servers
- 错误 ORA-01102: cannot mount database in EXCLUSIVE mode
- ORA-01102: cannot mount database in EXCLUSIVE mode
- ORA-01102: cannot mount database in EXCLUSIVE mode
- ORA-01102 cannot mount database in EXCLUSIVE mode 解决办法
- ORA-01102 cannot mount database in EXCLUSIVE mode
- ORA-01102: cannot mount database in EXCLUSIVE mode
- ORA-01102: cannot mount database in EXCLUSIVE mode
- ORA-01102: cannot mount database in EXCLUSIVE mode
- ORA-01102: cannot mount database in EXCLUSIVE mode
- ORA-01102: cannot mount database in EXCLUSIVE mode的解决办法
- ora-01102:cannot mount database in exclusive mode
- ORA-01102: cannot mount database in EXCLUSIVE mode
- ORA-01102: cannot mount database in EXCLUSIVE mode .
- ORA-01102: cannot mount database in exclusive mode
- ORA-ORA-01102: cannot mount database in EXCLUSIVE mode
- ORA-01102: cannot mount database in EXCLUSIVE mode
- ORA-01102: cannot mount database in EXCLUSIVE mode