Sunday, February 17, 2013

Converting Oracle APPS R12 to start and work with spfile instead of pfile


In this document
  • Introduction
  • Changing APPS to work with spfile
  • References



Introduction:

Oracle applications R12 (12.0.4 in our case) comes to start working using pfile.In most cases we are not able to change parameter without modifying the pfile and bounce the database.

A good and common practice is to convert the applications database to work with the spfile instead of the old fashion pfile. 

Changing Oracle APPS to work with spfile instead of pfile

1. To view if spfile exists on the system or not (for Linux) (database SID is "test")

$ cd $ORACLE_HOME/dbs
init.ora    inittest.ora        -- there is no spfile

2. To further check if the database is started using spfile or pfile

$ sqlplus / as sysdba
SQL> show parameter pfile
NAME    TYPE    VALUE
---------    -------     ----------
spfile      string

As you can see no value for the spfile.

3. Create a new spfile from pfile to make sure it is up to date.
SQL> create spfile from pfile;
File Created

This creates spfile under the defualt location $ORACLE_HOME/dbs, To check:
$ cd $ORACLE_HOME/dbs
$ ls 
init.ora    inittest.ora   spfiletest.ora

4. Take a backup of initTEST.ora, remove all the lines from this file, and have one line only --> spfile=/oracle/testdb/102/dbs/spfileTEST.ora

$ cp inittest.ora inittest.ora.bkp
$ vi inittest.ora
Remove all lines and add only the following line:
spfile=/oratest/db/tech_st/10.2.0/dbs/spfiletest.ora
 save and close the file

5. Stop any applications services, bounce the database and listener. Check to see which file you start with using
SQL> show parameter pfile
NAME    TYPE    VALUE
---------    -------     ----------
spfile      string     /oratest/db/tech_st/10.2.0/dbs/spfiletest.ora

6. Start Application services

Now you have APPS  R12 started with spfile, Enjoy.



References: 

How to Migrate from a Pfile to an Spfile [ID 166601.1]
https://forums.oracle.com/forums/thread.jspa?threadID=2152053

Hope this informative for you

Best Regards
Mostafa Mahmoud
February 2013


Related Articles:

Enable Enterprise Manager Database Control for Oracle E-Business Suite R12

 

1 comment:

Anonymous said...

Thanks Mostafa, helped me a lot.