Sunday, 21 April 2013

ORA-01102: cannot mount database in EXCLUSIVE mode

ORA-01102: cannot mount database in EXCLUSIVE mode


This error is encountered while starting an oracle 11gR2 database for the first time after the oracle software installation.

To resolve this issue, First I shutdown the oracle database instance. Then checked the oracle background processes of that instance.


[oracle@test dbs]$ ps -ef | grep ora_ | grep $ORACLE_SID
oracle    3306     1  0 13:25 ?        00:00:01 ora_pmon_testdb
oracle    3310     1  0 13:25 ?        00:00:00 ora_vktm_testdb
oracle    3316     1  0 13:25 ?        00:00:00 ora_gen0_testdb
oracle    3321     1  0 13:25 ?        00:00:00 ora_diag_testdb
oracle    3325     1  0 13:25 ?        00:00:00 ora_dbrm_testdb
oracle    3329     1  0 13:25 ?        00:00:00 ora_psp0_testdb
oracle    3333     1  0 13:25 ?        00:00:02 ora_dia0_testdb
oracle    3337     1  0 13:25 ?        00:00:00 ora_mman_testdb
oracle    3341     1  0 13:25 ?        00:00:00 ora_dbw0_testdb
oracle    3346     1  0 13:25 ?        00:00:00 ora_lgwr_testdb
oracle    3350     1  0 13:25 ?        00:00:02 ora_ckpt_testdb
oracle    3355     1  0 13:25 ?        00:00:01 ora_smon_testdb
oracle    3359     1  0 13:25 ?        00:00:00 ora_reco_testdb
oracle    3364     1  0 13:25 ?        00:00:01 ora_mmon_testdb
oracle    3368     1  0 13:25 ?        00:00:00 ora_mmnl_testdb
oracle    3373     1  0 13:25 ?        00:00:00 ora_d000_testdb
oracle    3377     1  0 13:25 ?        00:00:00 ora_s000_testdb
oracle    3457     1  0 13:25 ?        00:00:00 ora_qmnc_testdb
oracle    3463     1  0 13:25 ?        00:00:00 ora_q000_testdb
oracle    3467     1  0 13:25 ?        00:00:00 ora_q001_testdb
oracle    3495     1  0 13:25 ?        00:00:01 ora_cjq0_testdb
oracle    3888     1  0 13:30 ?        00:00:00 ora_smco_testdb


Killed all the processes owned by the oracle user.


[oracle@test dbs]$ kill -9 3306 3310 3316 3321 3325 3329 3333 3337 3341 3346 3350 3355 3359 3364 3368 3373 3377 3457 3463 3467 3495 3888
[oracle@test dbs]$ ps -ef | grep ora_ | grep $ORACLE_SID
[oracle@test dbs]$


Checked whether there are any files with the names  sgadef<sid>.dbf or lk<sid>. in $ORACLE_HOME/dbs. The sgadef<sid>.dbf or lk<sid> are used to lock the shared memory. Oracle always thinks that the memory is allocated to this instance even though no memory is allocated.

So I removed the file lkTESTDB


[oracle@test dbs]$ ls -lrt
total 28
-rw-r--r-- 1 oracle oinstall 2851 May 15  2009 init.ora
drwx------ 2 oracle oinstall 4096 Apr 21 11:45 peshm_testdb_0
-rw-r----- 1 oracle oinstall   24 Apr 21 12:04 lkTESTDB
-rw-r----- 1 oracle oinstall 1536 Apr 21 13:25 orapwtestdb
-rw-r--r-- 1 oracle oinstall  972 Apr 21 14:24 inittestdb.ora
-rw-r----- 1 oracle oinstall 2560 Apr 21 14:25 spfiletestdb.ora
-rw-rw---- 1 oracle oinstall 1544 Apr 21 15:14 hc_testdb.dat
[oracle@test dbs]$ rm lkTESTDB


Then I could start the database with out any issues.








3 comments: