Could not determine the AVDB SPFILE from "srvctl config database -d AVDB" when running modifyhostname.sh in RSA Via Lifecycle and Governance
4 years ago
Originally Published: 2016-03-23
Article Number
000064580
Applies To
RSA Product Set: RSA Via Lifecycle and Governance with local database
 
Issue
When trying to execute the modifyhostname.sh script to change the hostname, the script fails with following error.
Could not determine the AVDB SPFILE from "srvctl config database -d AVDB" 
​You may need to start oracle
Restarting Oracle does not resolve the issue. 

 
Cause
This happens when the SPFILE is not properly configured in the Oracle configuration. You can check the Oracle configuration by running command below.
srvctl config database -d AVDB
The output will look similar to this.
Database unique name: AVDB
Database name: AVDB
Oracle home: /u01/app/oracle/product/11.2.0/db_1
Oracle user: oracle
Spfile: +DG01/AVDB/spfileAVDB.ora
Domain:
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Database instance: AVDB
Disk Groups: DG01
Services:
If the SPFILE parameter is not configured correctly or if it is blank, you will run into this issue while running modifyhostname script.
Resolution
This issue has been resolved in 6.9.1 P13 and 7.0 P4.
Workaround
  1. Login to Oracle as sysdba using SQL*Plus or a similar client.
  2. Run the following command:
show parameter spfile;
The output will look like the sample below. The value may be different depending on the Oracle configuration.
NAME   TYPE   VALUE                                                  
------ ------ ------------------------------------------------------ 
spfile string /u01/app/oracle/product/12.1.0/db_1/dbs/spfileAVDB.ora
  1. SSH in to the RSA Via L&G server and run the following:
srvctl modify database -d AVDB -p <enter the string value received from Step 2>
  1. In this case, we would have to run the following command:
srvctl modify database -d AVDB -p /u01/app/oracle/product/11.2.0/db_1/dbs/spfileAVDB.ora
  1. Verify that the SPFILE is properly set by running this command:
srvctl config database -d AVDB

You will see that SPFILE value is now correctly updated as follows:

Database unique name: AVDB 
Database name: AVDB 
Oracle home: /u01/app/oracle/product/11.2.0/db_1 
Oracle user: oracle 
Spfile: /u01/app/oracle/product/12.1.0/db_1/dbs/spfileAVDB.ora
Domain: Start options: open Stop options: immediate 
Database role: PRIMARY Management policy: AUTOMATIC 
Database instance: AVDB 
Disk Groups: DG01 
Services:
  1. Run modifyhostname.sh again.