ORA-32001: Write To SPFILE Requested But No SPFILE Is In Use

Breadcrumb Abstract Shape
Breadcrumb Abstract Shape
Breadcrumb Abstract Shape
Breadcrumb Abstract Shape
Breadcrumb Abstract Shape
Breadcrumb Abstract Shape
  • User AvatarANKUSH THAVALI
  • 17 Dec, 2023
  • 0 Comments
  • 2 Mins Read

ORA-32001: Write To SPFILE Requested But No SPFILE Is In Use

Solution :

Generally , This error comes, if the database is running with pfile instead of spfile.
1. Check whether DB is running with pfile or spfile:
 SQL> show parameter pfile

NAME TYPE VALUE
------ -------- ------------------------------
spfile string

Here value is showing BLANK, Means database is running with pfile.

So with pfile , if we try to alter any init parameter in database, it will throw an error.

To fix it, create an spfile from the pfile and restart the database.

2. Create spfile from pfile;
 create spfile from pfile; 
3. Check whether spfile has been created in $ORACLE_HOME/dbs location:
 cd $ORACLE_HOME/dbs
ls -ltr spfile*
4. Restart the database
 shutdown immediate;
Startup
When we start the database, if both pfile(init$ORACLE_SID.ora) and spfile(spfile$ORACLE_SID.ora) are present at dbs location, Then bydefault spfile will be used to start database
5. Check whether spfile is used or not:
 show parameter pfile

NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
spfile string /data/app/oracle/product/dbhome/spfileprim.ora
6. Now run alter statement:
 ALTER SYSTEM SET processes = 900 SCOPE=SPFILE;

System altered.