Skip to content

Insight and analysis of technology and business strategy

Using asmcmd to Find the spfile and Password from ASM

I’m currently reviewing an environment that has been upgraded to 19c based on information from oratab. The reason for the review is to remove previously installed versions of the software.



Oracle software is installed to ORACLE_HOME, with variables pointing to directory location.

To my surprise, there are references to the previous ORACLE_HOME.

Here are the details:

--- Check oratab
[oracle@host.dr]/home/oracle>grep -Ev "^#|^$" /etc/oratab
testdb:/opt/oracle/product/19c/db_1:N         # line added by Agent
+ASM:/opt/oracle/product/19c/grid:N            # line added by Agent

--- ASM version
[oracle@host.dr]/home/oracle>asmcmd -V
The Oracle base remains unchanged with value /opt1/oracle
asmcmd version

--- Source ASM
[oracle@host.dr]/home/oracle>. oraenv <<< +ASM
[oracle@host.dr]/home/oracle>echo $ORACLE_HOME

--- Find DB spfile
[oracle@host.dr]/home/oracle>asmcmd find + spfile*

--- Find ASM spfile
[oracle@host.dr]/home/oracle>asmcmd spget

--- Find DB password file
[oracle@host.dr]/home/oracle>asmcmd find + pw*

--- Find ASM password file
[oracle@host.dr]/home/oracle>asmcmd pwget --asm

Based on the information found, the ASM password file and spfile are still residing in old homes.


  1. Verify all configurations before removing previous software versions.
  2. Before removing the directory, rename the directory and append old to it.
  3. After a defined time period, delete the directory.


I hope you found this post helpful. Feel free to drop any questions or share your thoughts in the comments, and make sure to sign up for updates.




Top Categories

  • There are no suggestions because the search field is empty.

Tell us how we can help!