Oracle Database Startup Basics
Oracle Database Startup Basics
Oracle will read the parameter file (spfile or pfile) in the default location or in the location
specified in the startup command.
It will then allocate the memory area (SGA) and starts the background processes. Together
we call it as the instance.
Please note that no database is associated with the instance at this point. We can start the
instance alone using the command:
$ sqlplus / as sysdba
SQL> startup nomount
ORACLE instance started.
To mount a database:
$ sqlplus / as sysdba
SQL> startup mount
To mount a database from nomount stage:
$ sqlplus / as sysdba
SQL> alter database mount
Open stage
This is the final stage and here Oracle opens the online datafiles and redolog files.
If any of the required files are not present, media recovery is required .
It also ensures the datafiles are consistent. Incase of a normal shutdown, the in-memory
changes will be written to disk as part of the shutdown checkpoint.
But if the instance crashed (or shutdown abort), then Oracle Database performs the instance
recovery in the next startup.
To open a database :
$ sqlplus / as sysdba
SQL> startup
To open a database from mount stage:
$ sqlplus / as sysdba
SQL> alter database open
To verify :
SQL> select open_mode from v$database;
OPEN_MODE
-------------------READ WRITE