Removing Oracle Database Software

About Oracle Deinstallation Options

The deinstall command removes Oracle Database, Grid Infrastructure, Oracle RAC, and Client software from an Oracle home, along with associated configuration. It must be run from the same release as the software being removed, and failed or inactive installations require complete configuration details interactively or through a response file. Before removing Grid Infrastructure, dismount ACFS, disable ADVM, and address any GNS DNS entries. If no other Oracle homes are registered, the command may delete Oracle base directories and can also remove database configuration, user data, and recovery files located outside the Oracle base.

Read More: About Oracle Deinstallation Options

Oracle Deinstallation (Deinstall)

The deinstall command stops and removes Oracle software and configuration for a specific Oracle home. It supports interactive, silent, validation-only, response-file, parameter override, output, temporary-file, and log-directory options. In clustered environments, -local limits software removal to the current node while deconfiguring remote nodes, and Grid Infrastructure options can preserve local or remote homes during deconfiguration. Use -help for additional command information.

Read More: Oracle Deinstallation (Deinstall)

Deinstallation Examples for Oracle Database

Run deinstall from the Oracle home’s deinstall directory to remove Oracle Database or Grid Infrastructure software. The command can run interactively or use a response file specified with -paramfile; response files can be generated with -checkonly or based on the provided template. For Grid Infrastructure, execute the command from the Grid home’s deinstall directory and supply the appropriate response file when required.

Read More: Deinstallation Examples for Oracle Database

Downgrading Oracle Restart

To downgrade or troubleshoot Oracle Restart, back up the database SPFILE, record database and Oracle Restart component configurations, and downgrade the database and its Restart resources when necessary. Stop all databases and listeners, deconfigure the current Oracle Restart installation with roothas.sh -deconfig -force, update the central inventory, unlock and reconfigure the previous-release Grid home, and restore databases, listeners, and services using their recorded attributes.

Read More: Downgrading Oracle Restart

Removing an RPM-based Oracle Database Installation

Remove an RPM-based Oracle Database installation as root with yum -y remove oracle-database-ee-19c. The command automatically handles the default database and listener, but stops if additional databases or listeners are configured. Remove those components manually with DBCA and NETCA as the Oracle software owner, then rerun the yum removal command as root.

Read More: Removing an RPM-based Oracle Database Installation

Deinstalling Previous Release Grid Home

To remove a previous-release Grid home after an upgrade, log in as root, correct the home and parent-directory permissions and ownership, then switch to the Grid Infrastructure software owner and run the deinstall command. The procedure uses the previous Grid home, installation owner, and inventory group values appropriate to the environment.
Read More: Deinstalling Previous Release Grid Home