Why won’t my database start when I send the dbstart command?

There is a known bug with the dbstart command on Oracle 9i (and possibly later) servers with databases with server parameter files (spfiles). This bug will cause your database not to start if there is no pfile (initSID.ora) in the default location. You will typically see the error below, followed by the sound of users whining.

bash-2.05$ dbstart

Can't find init file for Database "ORADB".
Database "ORADB" NOT started.

While there are a few options to remedy this, here are my two favorite.

Solution 1: Create a dummy pfile

I like to create a dummy pfile in the default location ($ORACLE_HOME/dbs/init$ORACLE_SID.ora) that contains only the following:

################################################################################
# This database uses an SPFILE to acquire it's parameters for startup.
# The spfile is located at $ORACLE_HOME/dbs/spfile$ORACLE_SID.ora
# This init file is here only as a placeholder so dbstart and dbshut
# work normally. For more info on spfiles see
# http://www.lifeaftercoffee.com/?p=76
# JE 1/6/2005
################################################################################

With this in place (for each database) the dbstart command works normally.

Solution 2: Create a pfile from the spfile

If you connect to the database, running or not, and execute the SQL command CREATE pfile FROM spfile; a pfile will be created in the default location. On startup the pfile will be ignored as long as there is an spfile. This allows dbstart to behave normally and also gives you a backup of the spfile; however this can become confusing and the pfile will not be kept up to date by the database.

For more information on spfiles and pfiles see my article Oracle pfile and spfile for parameters.

oracle, dba, database administration, database