Oracle RDBMS : DROP DATABASE - ORA-01586: database must be mounted EXCLUSIVE and not open for this operation

Following is an example where I deleted the entire database using 'DROP DATABASE' command.

Database SID : ORANGE
Version: 11.2.0.4
OS : HP UX Itanium

The database is in OPEN mode.

SYS@ORANGE SQL>drop database;
drop database
*
ERROR at line 1:
ORA-01586: database must be mounted EXCLUSIVE and not open for this operation


Solution:

SYS@ORANGE SQL>shutdown immediate;
Database closed.
Database dismounted.
ORACLE instance shut down.
SYS@ORANGE SQL>startup mount exclusive restrict;
ORACLE instance started.

Total System Global Area 2121183232 bytes
Fixed Size                  2207208 bytes
Variable Size            1275068952 bytes
Database Buffers          838860800 bytes
Redo Buffers                5046272 bytes
Database mounted.
SYS@ORANGE SQL>drop database;

Database dropped.

Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SYS@ORANGE SQL>

No comments:

Post a Comment