PFile and SPFile in oracle

  PFile and SPFile in oracle

Pfile

SPfile

init<sid>.ora

spfile<sid>.ora

Text file

Binary file

Edited in text editor

Edited by using ALTER SYSTEM SET

Edit pfile and start DB to test new parameter

Once test as pfile, finally update spfile

 Start DB with pfile:

SQL> startup pfile=”path of file”

Change parameter in SPfile:

SQL> ALTER SYSTEM SET log_archive_start = TRUE SCOPE = spfile;

If scope = BOTH, it updates pfile also.

Create spfile from pfile and vice versa:

SQL> create spfile from pfile;

SQL> create pfile from spfile;

Here is an alternative procedure for changing SPFILE parameter values using the above method:

  • Export the SPFILE with: CREATE PFILE=’pfilename’ FROM SPFILE = ‘spfilename’;
  • Edit the resulting PFILE with a text editor

  • Shutdown and startup the database with the PFILE option: STARTUP PFILE=filename
  • Recreate the SPFILE with: CREATE SPFILE=’spfilename’ FROM PFILE=’pfilename’;
  • On the next startup, use STARTUP without the PFILE parameter and the new SPFILE will be used.

Post a Comment

0 Comments

  PFile and SPFile in oracle