Skip Headers
Oracle® Real Application Clusters Installation Guide
11g Release 1 (11.1) for Linux and UNIX

Part Number B28264-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Master Index
Master Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
View PDF

8 Removing Oracle RAC and ASM Software

This chapter describes how to completely remove all Oracle databases, instances, and software from an Oracle Real Application Clusters (Oracle RAC) Oracle home directory.

This chapter contains the following topics:

See Also:

If you want to remove an individual product, refer to the product-specific documentation for requirements and restrictions

8.1 Overview of Deinstallation Procedures

To completely remove all Oracle databases, instances, and software from an Oracle home directory:

Note:

You cannot remove or uninstall the Oracle Database Vault option. However, you can disable it. Refer to Oracle Database Vault Administrator's Guide for more details.

You can remove Oracle Configuration Manager. Refer to Oracle Configuration Manager Installation and Administration Guide for more details.

8.2 Identifying All Instances On a Cluster

To identify all instances associated with the Oracle home that you want to remove, enter the following command:

AIX, HP-UX, or Linux:

$ more /etc/oratab

Solaris

$ more /var/opt/oracle/oratab

The output of this command contains entries similar to the following:

+ASM1:/u01/app/oracle/product/11.1.0/db_1:N
CUST:/u01/app/oracle/product/11.1.0/db_1:N

These entries show that the +ASM Automatic Storage Manager instance and the CUST Oracle database instance are associated with the Oracle home directory /u01/app/oracle/product/11.1.0/db_1.

8.3 Deinstalling Oracle RAC Software

Perform the following procedures to de-install Oracle RAC:

See Also:

Oracle Real Application Clusters Administration and Deployment Guide for more information about using Oracle RAC scalability features of adding and deleting nodes and instances from Oracle RAC databases, and for information about viewing OCR content

8.3.1 Deinstalling Oracle RAC and ASM Using Configuration Assistants

This section describes the procedure to remove the Oracle RAC software and Automatic Storage Management (ASM) software using configuration assistant command lines.

  1. Examine the oratab file to identify the instance dependencies on this Oracle home.

  2. Start DBCA, select Oracle Real Application Clusters Database, select Delete a database, and select the database that you want to delete. Repeat this step to delete all databases.

  3. If you do not use ASM, then proceed to step 4.

    If the database is in the Oracle home from which the ASM database runs, then ensure that there are no other database dependencies on this group of ASM instances.

    If Oracle RAC and ASM are owned by the same Oracle user account, then log in as that user (typically oracle).

    If Oracle RAC and Oracle ASM are owned by different software owners, then remove the Oracle RAC installation by logging in as the Oracle RAC software owner, and remove ASM by logging in as the ASM software owner.

    To remove the software, complete the following steps

    1. Connect to the ASM instance and run the following command to determine database instances using this ASM instance:

      SQL> select INSTANCE_NAME from GV$ASM_CLIENT;
      

      Note:

      This command lists only database instances that are running. It is possible that other instances are associated with the ASM instance, but they are not currently running. If you removed a database from this Oracle home but the output from the command shows that this ASM instance is supporting a database instance in another Oracle home, then do not remove the ASM instance or the Oracle home.

      If your Oracle RAC database uses a different Oracle home from the Oracle home that your ASM environment uses, and you want to delete the Oracle RAC database, then perform step 5 in the Oracle RAC database home.

    2. For each instance listed in the output of the statement you run in step a, stop the respective databases.

    3. Oracle recommends that you back up the database files for all the databases that are currently using this ASM instance.

    4. Using your connection to the ASM instance, run the following command:

      SQL> select * from V$ASM_DISKGROUP;
      
    5. For each disk group listed in the output of the statement you run in step d, run the following command:

      SQL> drop diskgroup diskgroup_name including contents;
      

      The variable diskgroup_name is the name of the disk group that you want to delete.

    6. Shut down ASM on all Oracle RAC nodes, and verify that all ASM instances are stopped.

    7. If you are de-installing from a system with ASMLIB, then run the following procedure. First, run this command to list the disks that you need to delete:

      oracleasm listdisks
      

      Second, run the following command to delete every disk listed by the previous command:

      oracleasm deletedisks
      

      Third, re-run the oracleasm listdisks command to confirm that the disks are all deleted. Repeat this command on each of the Oracle RAC cluster nodes to confirm that the disks have been deleted from all the nodes.

      Fourth, as root, run the following commands on all nodes of your Oracle RAC cluster:

      /etc/init.d/oracleasm stop/etc/init.d/oracleasm disable
      
    8. Deconfigure ASM, using either DBCA in silent mode, or performing deconfiguration manually.

      To deconfigure ASM manually, complete steps i through l.

      To deconfigure ASM using DBCA, run DBCA in silent mode to deconfigure ASM. To run DBCA in silent mode, navigate to the directory $ORACLE_HOME/bin and use the following command syntax:

      dbca -silent -deleteASM -nodelist node1,node2,...
      

      for the variables node1, node2, and so on, provide a list of all the nodes where ASM is configured. When DBCA completes de-installation, proceed to step 4.

    9. To remove the ASM entry from the OCR, run the following command for all nodes on which this Oracle home exists:

      srvctl remove asm -n nodename
      

      where nodename is the name of a node from which you want to remove the ASM instance. Repeat this command for each node on which you want to remove ASM.

    10. If you are using a shared cluster file system for your Oracle home, then run the following commands on the local node:

      rm -Rf $ORACLE_HOME/dbs/*ASM*
      rm -Rf $ORACLE_BASE/admin/+ASM
      

      You may need to remove subordinate files or directories before these commands complete successfully.

    11. If you are not using a shared cluster file system for your Oracle home, then run the commands from the previous step, step j, on each node on which the Oracle home exists.

    12. Remove oratab entries for the deleted Oracle home databases.

  4. If there are no outstanding dependencies, then change directory to the $ORACLE_HOME/bin directory, and use the following NETCA command syntax to remove the listener and its Oracle Clusterware resources.

    $ ./netca /deinst /nodeinfo node1,node2,...
    

    In the preceding syntax example, replace the variables node1, node2, and so on, with all the member nodes of the Oracle RAC database.

    Note:

    You cannot perform an Oracle RAC installation from the same Oracle Universal Installer session in which you perform an Oracle RAC deinstallation. If you deinstall Oracle RAC with OUI and want to perform another Oracle RAC installation, then you must start a new OUI session.
  5. Start OUI, and remove any existing Oracle Database with Oracle RAC software by selecting Deinstall Products, and selecting the Oracle home that you want to remove. If any of these databases is an ASM database, then de-install the Oracle home with ASM where you want to de-install the Oracle Database software, and then de-install the Oracle Database. Removing ASM does not remove the ASM data or disk groups.

8.3.2 Deinstalling Oracle Clusterware

Deinstall each Oracle RAC home by running the procedure in the previous section, "Deinstalling Oracle RAC and ASM Using Configuration Assistants". Then complete the deinstallation by removing the Oracle Clusterware software. Refer to Oracle Clusterware Installation Guide for your platform for Oracle Clusterware deinstallation procedures.

8.4 Removing Oracle Software

The following steps describe how to use Oracle Universal Installer (OUI) to remove Oracle software from an Oracle home:

Note:

Always use OUI to remove Oracle software. Do not delete any Oracle home directories without first using OUI to remove the software.
  1. If necessary, log in as the oracle user:

    $ su - oracle
    
  2. Set the ORACLE_HOME environment variable to specify the path of the Oracle home directory that you want to remove:

    • Bourne, Bash, or Korn shell:

      $ ORACLE_HOME=/u01/app/oracle/product/11.1.0/db_1 
      $ export ORACLE_HOME
      
    • C shell:

      $ setenv ORACLE_HOME /u01/app/oracle/product/11.1.0/db_1
      
  3. Remove any databases or Automatic Storage Management instances associated with this Oracle home and delete the Oracle CSS daemon.

    Refer to the preceding sections for information about how to complete these tasks.

  4. Stop any processes running in this Oracle home:

    Process Name Command
    Database Control $ORACLE_HOME/bin/emctl stop dbconsole
    Oracle Net listener $srvctl stop listener -n nodename
    Oracle Ultra Search $ORACLE_HOME/bin/searchctl stop

  5. Start OUI as follows:

    $ $ORACLE_HOME/oui/bin/runInstaller
    
  6. In the Welcome window, click Deinstall Products.

    The Inventory screen appears, listing all of the Oracle homes on the system.

  7. In the Inventory screen, select the Oracle home and the products that you want to remove, then click Remove.

    Note:

    If you choose to remove Oracle JVM, then OUI removes all installed products that depend on Oracle JVM, including Oracle Database 10g.

    OUI displays a confirmation window asking you to confirm that you want to deinstall the products and their dependent components.

  8. Click Yes.

    OUI displays a progress indicator as it removes the software.

  9. Click Close on the Inventory screen.

  10. When the products have been deleted, click Cancel to exit from OUI, and then click Yes.