Fix for BR1830W Oracle profile <init.ora> should contain only the ‘spfile’ parameter
Upon updating to BR*Tools 7.40 Patch 34, all the brtools operations may have turned yellow due to this new warning:
BR1830W Oracle profile '$ORACLE_HOME/dbs/init<DBSID>.ora' should contain only the 'spfile' parameter
(Screenshot above was for 12.1.)
The warning happens in the beginning of the operation therefore it will appear in the beginning of the detail log.
We will see why the warning was added and how to avoid the warning.
Why was this warning added?
The note for this warning, #2659458, explains why this warning was added (to avoid confusion when additional parameters are in the init<DBSID>.ora) and, for when the new ’oracle’ user concept is in use, refers to #1598594 for how to avoid the warning.
What is needed to avoid the warning
However that note does not provide an actual example of the format so here is one to adopt that came from a system newly installed with SWPM:
#Generate initsid.ora for spfile spfile = (/oracle/<DBSID>/121/dbs/spfile<DBSID>.ora)
This example is for 12.1 obviously and not 12.2 and the official Oracle (12.1) documentation for the SPFILE parameter is here.
Many formats will work (acceptable to both Oracle and the BR*Tools) including without the parenthesis, single quotes instead of the parenthesis, no spaces around the equal sign, uppercase parameter name SPFILE, etc.and the comment line is not necessary. Which to choose does not matter much but going with the above two-line file just for the general system administration reason of wanting systems to be configured alike including having upgraded systems resemble newly installed systems as much as possible.
Side-topic: “transparent copy” of the profile
If you miss the plain text full pfile as a reference (as compared to possibly passing the spfile through a utility such as ‘strings’ to read it without the extra characters), the note #1598594 explains the ‘sapprof’ directory, where if you run a BR*Tools operation such as the DB Check daily, then daily a full pfile will be generated there (from the live spfile) that is just for reference by the tools or administrators.
Are assuming all systems are using an spfile, but can confirm by checking the alert log, for example:
grep 'Using parameter settings in' /oracle/<DBSID>/saptrace/diag/rdbms/<DB_UNIQUE_NAME>/<DBSID>/trace/alert_<DBSID>.log | tail -1
(In non-Data Guard systems the DB_UNIQUE_NAME in the path is likely just the lowercase <dbsid>.)
Using parameter settings in server-side spfile /oracle/<DBSID>/121/dbs/spfile<DBSID>.ora
(Example for 12.1.)
(Anything other than server-side spfile would be logged here, such as ‘pfile’.)
- Replace the pfile in $ORACLE_HOME/dbs with your template file and edit in two places for the correct DBSID.
- Compare the permissions of the new pfile with that of the spfile and make the permissions of the new pfile match that of the spfile.
(Since assuming it is already using a spfile, the note #2659458 explains that any other parameters in the pfile are already being ignored, no restart of the DB is needed.)
Now that this particular warning has been avoided, other more important warnings can more easily be noticed.
Any number of formats for the new one-parameter pfile will work and probably the person at SAP who coded the file generation in SWPM did not intend that format as a standard, but choosing that format regardless. Overall which format to use is a minor choice.
BR*Tools 7.40 Patch 34
SWPM 1.0 SP21
Oracle 12.1 non-ASM with new ’oracle’ user concept