Solved

Pfile and SPfile - Oracle

Posted on 2016-10-12
2
95 Views
Last Modified: 2016-10-12
Hi,

  I have a few questions regarding Pfile and SPfile.    I am a bit confuse.

  a) How can i check if my database was started using spfile or pfile ?

  b) How can i check if both the Pfile and SPfile has the same configuration ?

  c) When starting a database using the sqlplus command "start"  --- does it uses the spfile or the pfile ?

  d) Where is the location of the spfile and the pfile ?

  e)  Does the Init file is the same as the pfile ?

  f)  When executing "Show Parameters " using SqlPlus  , it gets the information from the Pfile or from SPfile ?

Regards,

 Joe.
0
Comment
Question by:joe_echavarria
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 22

Accepted Solution

by:
Steve Wales earned 500 total points
ID: 41840408
a) Tom Kyte answers that one here: https://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:6644781942843

Basically there's a system view v$spparameter that you can query - if all settings are false, no SPFILE, if any are true then yes, SPFILE.

You could also do "show parameter spfile" - if there's a value there, that's the spfile you started the instance with.

b) Only way I could think of would be to create a text version of your spfile:  create pfile=xx.txt from spfile - and compare to your pfile.

c) If an spfile exists in the default location it uses that, else pfile if it's in the default location

d) $ORACLE_HOME/dbs for Unix, %ORACLE_HOME%\database for Windows (same default for both pfile/spfile)

e) Yes, different name for the same thing.

f) It gets information from whichever of the parameter files you started the instance with.  By the time the instance is started, those parameters are in memory and that's what you're running the instance with.   That's what show parameter reports.
0
 
LVL 77

Expert Comment

by:slightwv (䄆 Netminder)
ID: 41840566
To add to the above post:

c) unless you specify the location on the start command itself.

d) it can be outside of the default location if the DBA wants it to be.

f) it also shows current values for your session.  

For example:
show parameter nls_date_format

That is the current format for your session.

If you:  alter session set nls_date_format='MM-DD-YYYY';

You will see that format and not the one in the pfile/spfile.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
SQL2016 to ORACLE11G linked-server 6 79
Row_number in SQL 6 56
format dd/mm/yyyy parameter 16 59
how to tune the query 17 85
Working with Network Access Control Lists in Oracle 11g (part 1) Part 2: http://www.e-e.com/A_9074.html So, you upgraded to a shiny new 11g database and all of a sudden every program that used UTL_MAIL, UTL_SMTP, UTL_TCP, UTL_HTTP or any oth…
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Via a live example, show how to take different types of Oracle backups using RMAN.

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question