Applying patch using Oracle OPatch online and offline

[oracle@ol6 downloads]$ unzip p11678127_112020_Linux-x86-64.zip [oracle@ol6 downloads]$ cd 11678127 [oracle@ol6 11678127]$ $GRID_HOME/OPatch/opatch apply
 * Installing in Online Mode

[oracle@ol6 downloads]$ unzip p11678127_112020_Linux-x86-64.zip [oracle@ol6 downloads]$ cd 11678127 [oracle@ol6 11678127]$ $GRID_HOME/OPatch/opatch rollback -id 11678127
 * Deinstalling in Offline Mode

--- To install the patch in online mode, follow these steps: Note: In case of an Oracle RAC environment, perform these steps on each of the nodes.
 * Installing in Online Mode

1.	Maintain a location for storing the contents of the patch ZIP file. In the rest of the document, this location (absolute path) is referred to as .

2.	Extract the contents of the patch ZIP file to the location you created in Step (1). To do so, run the following command: $ unzip -d  p11678127_112020_Linux-x86-64.zip

3.	Navigate to the /11678127 directory: $ cd /11678127

4.	Install the patch by running the following command: -	For Non-RAC Environments (Standalone Databases): $ opatch apply online -connectString ::: -	For RAC Environments: $ opatch apply online -connectString :::,:::,:<Username_NodeN>:<Password_NodeN>:<NodeN_Name> <PATCH_TOP_DIR>/11678127

Note: -	Run the previous command on the first node of the Oracle RAC system, and specify details of each node separated by a comma. In the command, NodeN refers to the different nodes of the Oracle RAC system. Once the patch is applied on the first node, OPatch automatically moves over and patches the next node you have specified in the comamnd. -	When OPatch starts, it validates the patch and ensures that there are no conflicts with the software already installed in the ORACLE_HOME of the Oracle Database. OPatch categorizes conflicts into the following types: -	Conflicts with a patch already applied to the ORACLE_HOME that is a subset of the patch you are trying to apply - In this case, continue with the patch installation because the new patch contains all the fixes from the existing patch in the ORACLE_HOME. The subset patch will automatically be rolled back prior to the installation of the new patch. -	Conflicts with a patch already applied to the ORACLE_HOME - In this case, stop the patch installation and contact Oracle Support Services.

5.	Start the services from the Oracle home.

-- To deinstall the patch in online mode, follow these steps: Note: In case of an Oracle RAC environment, perform these steps on each of the nodes.
 * Deinstalling in Online Mode

1.	Navigate to the <PATCH_TOP_DIR>/11678127 directory: $ cd <PATCH_TOP_DIR>/11678127

2.	Deinstall the patch by running the following command: -	For Non-RAC Environments (Standalone Databases): $ opatch rollback -id 11678127 -connectString <SID>:<USERNAME>:<PASSWORD>: -	For RAC Environments: $ opatch rollback -id 11678127 -connectString <SID_Node1>:<Username_Node1>:<Password_Node1>:<Node1_Name>,<SID_Node2>:<Username_Node2>:<Password_Node2>:<Node2_Name>,<SID_NodeN>:<Username_NodeN>:<Password_NodeN>:<NodeN_Name> <PATCH_TOP_DIR>/11678127

Note: Run the previous command on the first node of the Oracle RAC system, and specify details of each node separated by a comma. In the command, NODEn refers to the different nodes of the Oracle RAC system. Once the patch is rolled back from the first node, OPatch automatically moves over and rolls back the patch from the next node you have specified in the comamnd.

3.	Start the services from the Oracle home.