Skip Headers
Oracle® Grid Infrastructure Installation Guide
11g Release 2 (11.2) for Solaris Operating System

Part Number E10816-03
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

6 How to Modify or Deinstall Oracle Grid Infrastructure

This chapter describes how to remove Oracle Clusterware and Oracle ASM.

This chapter contains the following topics:

See Also:

Product-specific documentation for requirements and restrictions to remove an individual product

6.1 Deciding When to Deinstall Oracle Clusterware

Remove installed components in the following situations:

6.2 Migrating Standalone Grid Infrastructure Servers to a Cluster

If you have an Oracle Database installation using Oracle Restart (that is, an Oracle grid infrastructure installation for a standalone server), and you want to configure that server as a cluster member node, then complete the following tasks:

  1. Inspect the Oracle configuration with srvctl using the following syntax, where db_unique_name is the unique name for the database, and lsnrname is the name of the listeners:

    srvctl config database -d db_unique_name

    srvctl config service -d db_unique_name

    srvctl config listener -l lsnrname

    Write down the configuration information for the server.

  2. Change directory to Grid home/crs/install. For example:

    # cd /u01/app/11.2.0/grid/crs/install
    
  3. Deconfigure and deinstall the Oracle grid infrastructure installation for a standalone server, using the following command:

    # roothas.pl -deinstall
    
  4. Prepare the server for Oracle Clusterware configuration, as described in this document.

  5. Clone the Oracle grid infrastructure for a cluster software from an existing node, or install and configure Oracle grid infrastructure for a cluster.

  6. Add the Oracle Database for support by Oracle grid infrastructure for a cluster, using the configuration information you recorded in step 1. Use the following command syntax, where db_unique_name is the unique name of the database on the node, and nodename is the name of the node:

    srvctl add database -d db_unique_name -o $ORACLE_HOME -x nodename

    For example, with the database name mydb_node1, and the nodename node1, enter the following command:

    srvctl add database -d mydb_node1 -o $ORACLE_HOME -x node1
    
  7. Add each service to the database, using the command srvctl add service.

6.3 Relinking Oracle Grid Infrastructure for a Cluster Binaries

After installing Oracle grid infrastructure for a cluster (Oracle Clusterware and Oracle ASM configured for a cluster), if you need to modify the binaries, then use the following procedure, where Grid_home is the grid infrastructure for a cluster home:

Caution:

Before relinking executables, you must shut down all executables that run in the Oracle home directory that you are relinking. In addition, shut down applications linked with Oracle shared libraries.

As root:

# cd Grid_home/crs/install
# perl rootcrs.pl -unlock

As the grid infrastructure for a cluster owner:

$ export ORACLE_HOME=Grid_home
$ Grid_home/bin/relink

As root again:

# cd Grid_home/crs/install
# perl rootcrs.pl -patch

You must relink the Oracle Clusterware and Oracle ASM binaries every time you apply an operating system patch or after an operating system upgrade.

6.4 Deconfiguring Oracle Clusterware Without Removing Binaries

Running the rootcrs.pl command flags -deconfig -force enables you to deconfigure Oracle Clusterware on one or more nodes without removing installed binaries. This feature is useful if you encounter an error on one or more cluster nodes during installation when running the root.sh command, such as a missing operating system package on one node. By running rootcrs.pl -deconfig -force on nodes where you encounter an installation error, you can deconfigure Oracle Clusterware on those nodes, correct the cause of the error, and then run root.sh again.

To deconfigure Oracle Clusterware:

  1. Log in as the root user on a node where you encountered an error.

  2. Change directory to Grid_home/crs/install. For example:

    # cd /u01/grid/crs/install
     
    
  3. Run rootcrs.pl with the -deconfig -force flags. For example:

    # perl rootcrs.pl -deconfig -force
    

    Repeat on other nodes as required.

  4. If you are deconfiguring Oracle Clusterware on all nodes in the cluster, then on the last node, enter the following command:

    # perl rootcrs.pl -deconfig -force -lastnode
    

    The -lastnode flag completes deconfiguration of the cluster, including the OCR and voting disks.

6.5 Removing Oracle Database 11g

The deinstall command removes Oracle Clusterware and ASM from your server. The following sections describe the command, and provide information about additional options to use the command:

6.5.1 About the Deinstallation Tool

The Deinstallation Tool (deinstall) is available in the installation media before installation, and is available in Oracle home directories after installation. It is located in the path $ORACLE_HOME/deinstall.

The deinstall command stops Oracle software, and removes Oracle software and configuration files on the operating system.

The command uses the following syntax, where variable content is indicated by italics:

deinstall -home complete path of Oracle home [-silent] [-checkonly] [-local]
[-paramfile complete path of input parameter property file] [-params name1=value
name2=value . . .] [-o complete path of directory for saving files] [-help | -h]
 

The options are:

  • -home

    Use this flag to indicate the home path of the Oracle home that you want to check or deinstall. To deinstall Oracle software using the deinstall command in the Oracle home you plan to deinstall, provide a parameter file in another location, and do not use the -home flag.

  • -silent

    Use this flag to run the command in noninteractive mode. This option requires a properties file that contains the configuration values for the Oracle home that is being deinstalled or deconfigured.

    To create a properties file and provide the required parameters, refer to the template file deinstall.rsp.tmpl, located in the response folder. If you prefer, instead of using the template file, you can generate a properties file by using the -checkonly option to have deinstall discover information from the Oracle home that you want to deinstall and deconfigure. It generates the properties file, which you can then use with the -silent option.

  • -checkonly

    Use this flag to check the status of the Oracle software home configuration. Running the command with the checkonly flag does not remove the Oracle configuration.

  • -local

    Use this flag on a multinode environment to deconfigure Oracle software in a cluster.

    When you run deinstall with this flag, it deconfigures and deinstalls the Oracle software on the local node (the node where deinstall is run). On remote nodes, it deconfigures Oracle software, but does not deinstall the Oracle software.

  • -paramfile complete path of input parameter property file

    Use this flag to run deinstall with a parameter file in a location other than the default. When you use this flag, provide the complete path where the parameter file is located.

    The default location of the parameter file depends on the location of deinstall:

    • From the installation media or stage location: $ORACLE_HOME/inventory/response.

    • From a unzipped archive file from OTN: /ziplocation/response.

    • After installation from the installed Oracle home: $ORACLE_HOME/deinstall/response.

  • -params [name1=value name2=value name3=value ...]

    Use this flag with a parameter file to override one or more values in a parameter file you have already created.

  • -o complete path of directory for saving response files

    Use this flag to provide a path other than the default location where the properties file (deinstall.rsp.tmpl) is saved.

    The default location of the parameter file depends on the location of deinstall:

    • From the installation media or stage location before installation: $ORACLE_HOME/

    • From a unzipped archive file from OTN: /ziplocation/response/.

    • After installation from the installed Oracle home: $ORACLE_HOME/deinstall/response.

  • -help | -h

    Use the help option (-help or -h) to obtain additional information about the command option flags.

6.5.2 Example of Running the Deinstall Command for Oracle Clusterware and ASM

As the deinstall command runs, you are prompted to provide the home directory of the Oracle software that you want to remove from your system. Provide additional information as prompted.

To run the deinstall command from an Oracle grid infrastructure for a cluster home in the path /u01/app/11.2.0/grid, where you are running the command using the parameter file in the software owner location /home/usr/grid, enter the following command:

$ cd /u01/app/11.2.0/grid/deinstall/
$ ./deinstall -paramfile /home/usr/grid/myparamfile.tmpl

You can generate the parameter file by running the deinstall command using the -checkonly flag before you run the command to deinstall the home, or you can use the response file template and manually edit it to create the parameter file to use with the deinstall command.

6.5.3 Example of a Deinstallation Parameter File for Grid Infrastructure for a Cluster

You can run the deinstall command with the -paramfile option to use the values you specify in the parameter file. The following is an example of a parameter file for a cluster on nodes node1 and node2, in which the Oracle grid infrastructure for a cluster software binary owner is grid, the Oracle grid infrastructure home (Grid home) is in the path /u01/app/11.2.0/grid, the Oracle base (the Oracle base for grid infrastructure, containing Oracle ASM log files, Oracle Clusterware logs, and other administrative files) is /u01/app/grid/, the central Oracle Inventory home (oraInventory) is /u01/app/oraInventory, the virtual IP addresses (VIP) are 192.0.2.2 and 192.0.2.4, the local node (the node where you are running the deinstallation session from) is node1:

#Copyright (c) 2005, 2006 Oracle Corporation.  All rights reserved.
#Fri Feb 06 00:08:58 PST 2009
LOCAL_NODE=node1
HOME_TYPE=CRS
ASM_REDUNDANCY=\
ORACLE_BASE=/u01/app/grid/
VIP1_MASK=255.255.252.0
NEW_NODEVIPS='node1-vip/255.255.252.0/eth0,node2-vip/255.255.252.0/eth0'
VOTING_DISKS=/u02/storage/grid/vdsk
SCAN_PORT=1522
silent=true
ASM_UPGRADE=false
ORA_CRS_HOME=/u01/app/11.2.0/grid
GPNPCONFIGDIR=$ORACLE_HOME
LOGDIR=/home/grid/SH/deinstall/logs/
GPNPGCONFIGDIR=$ORACLE_HOME
ORACLE_OWNER=grid
NODELIST=node1,node2
CRS_STORAGE_OPTION=2
NETWORKS="eth0"/192.0.2.1\:public,"eth1"/10.0.0.1\:cluster_interconnect
VIP1_IP=192.0.2.2
NETCFGJAR_NAME=netcfg.jar
ORA_DBA_GROUP=dba
CLUSTER_NODES=node1,node2
JREDIR=/u01/app/11.2.0/grid/jdk/jre
VIP1_IF=eth0
REMOTE_NODES=node2
VIP2_MASK=255.255.252.0
ORA_ASM_GROUP=asm
LANGUAGE_ID='AMERICAN_AMERICA.WE8ISO8859P1'
CSS_LEASEDURATION=400
NODE_NAME_LIST=node1,node2
SCAN_NAME=node1scn
SHAREJAR_NAME=share.jar
HELPJAR_NAME=help4.jar
SILENT=false
local=false
INVENTORY_LOCATION=/u01/app/oraInventory
GNS_CONF=false
JEWTJAR_NAME=jewt4.jar
OCR_LOCATIONS=/u02/storage/grid/ocr
EMBASEJAR_NAME=oemlt.jar
ORACLE_HOME=/u01/app/11.2.0/grid
CRS_HOME=true
VIP2_IP=192.0.2.4
ASM_IN_HOME=n
EWTJAR_NAME=ewt3.jar
HOST_NAME_LIST=node1,node2
JLIBDIR=/u01/app/11.2.0/grid/jlib
VIP2_IF=eth0
VNDR_CLUSTER=false
CRS_NODEVIPS='node1-vip/255.255.252.0/eth0,node2-vip/255.255.252.0/eth0'
CLUSTER_NAME=node1-cluster  

As an Amazon Associate I earn from qualifying purchases.