Thursday, September 29, 2022

How to Apply Patch on Oracle Enterprise Manger 13c (13.4/13.5) Agent in online / offline mode

Oracle Enterprise Manager (EM) 13.4/13.5 agent patch is released as one-off patch, Release Update, or bundle patches. These patches can be applied manually or through EM Cloud Control console.

1. Apply patch with EM Cloud control console

1.1 Determine if EM is configured in OFFLINE or ONLINE mode

* In Cloud Control console, from the Setup menu, select Provisioning and Patching, and then click Offline Patching.

On the Offline Patching page, if Online/Offline radio button is selected, EM is configured in Online/Offline mode.

If Offline is selected, you can download the patch/update catalog file from the URL showing on the page ( and upload it into EM from this page. it is optional to do that, but highly recommended. Otherwise, EM compliance cannot be evaluated with up-to-date security/update recommendation.

1.2 Download the required patch from Oracle Support

If it is Release Update for EM 13.5, it is also needed to download proper version of AgentPatcher.

For example, Enterprise Manager 13c Release 5 Update 8 ( for Oracle Management Agent (Patch 34158585), it requires AgentPatcher version or later for Enterprise Manager release. Therefore, we have to download both Patch 34158585 (EM Agent Release Update and Patch 33355570 (AgentPatcher release for Enterprise Manager 13.5).

If EM is working in Offline mode, you have to manually log into Oracle Support portal to download the patch files. If in Online mode, the patch can be downloaded as folloiwng,

In Cloud Control console, from Enterprise menu, select Provisioning and Patching, and then click Patches and Updates, search for the patch and download to Software Library.

1.3 Upload downloaded patch files to the EM Software Library if they are manually downloaded

* In Cloud Control console, from the Enterprise menu, select Provisioning and Patching, and the click Saved Patches

* On Saved Patches page, click the Upload button

* On Upload a Patch pop-up windown, select the downloaded patch file for Patch Zip File, then click Upload button. Repeat same steps to upload all downloaded Patch Zip files including AgentPatcher if applicable.

Note: Patch Metadata file is not needed if the Patch Zip File already contents the metadata. This is most cases. If not, you have to download Patch Metadata while downloading Patch Zip file. 

1.4 Create a patch plan for the patch uploaded into Software Library

* In Cloud Control console, from the Enterprise menu, select Patching and Provisioning, and then click Patches and Updates

* On the Patches and Updates page, in the Patch Search Region, enter the patch number (e.g. 34158585), and click Search

* In Patch Search Results list, select the patch or click the patch number, and click Create Plan.

* In Create New Plan dialog box, enter a unique name for the plan, and click Add button.

* In Select Targets dialog box, select Agent for Target Type, then click the search button. From the list, select the Management Agent target (or group of targets) that needs to be patched. Ensure that you add at least one target of type agent, and then click Select and back to Create New Plan dialog box.

* In Create New Plan dialog box, click Create Plan.

1.5 Start/schedule the patch plan

On the Patches and Updates page, in the Plans region, click the Patch Plan you created in the previous step. It brings up the patch plan wizard.

* On the Plan Information page, in the Overview section, validate the Patch Plan name. You can choose to edit it if you want.

(Optional) Select a date and time when you want to deploy the Patch Plan, and enter a short description to describe the Patch Plan.

Click Next.

* On the Patches page, review the patches added to the Patch Plan, then Click Next.

* On the Deployment Options page, do the following:

In Options section, Leave the default location (%emd_emstagedir%) for Stage Location, or edit the Stage Location to provide a new location for staging the Management Agent patches.

In Oracle Home Credentials section, select Oracle Home Preferred Credentials if you have already set them earlier. You can otherwise click Override Oracle Home Preferred Credentials to set the Normal Oracle Home Credentials and Privileged Oracle Home Credentials, to access the Oracle home of the target.

Note: Do not check/select OPatch Upgrade option.

Click Next.

* On the Validation page, click Analyze to check for conflicts. If there are conflicts, then review the issues, and resolve it according to the corresponding solutions available on the page. After resolving the issue, click Re-Analyze.

Click Next.

* On the Review & Deploy page, review the details you have provided for the patch plan, then click Deploy.

2. Manually apply patches for Management Agent

2.1 OPath and AgentPatcher

If you are applying EM Agent 13.5 Release Update (RU), AgentPatcher is needed. Otherwise OPatch will be used. Usually, it does not need to update OPatch version unless it is explicitly requested in the patch (or patch bundle) installation instruction (Read Me file).

If AgentPatcher is needed, make sure its version satisfy with the EM Agent 13.5 RU installation instruction (ReadMe file). The latest AgentPatcher can be installed as following

* Download Patch 33355570 for EM from My Oracle Support.

* Copy the zip file "" to the EM 13.5 Agent Home.

  Agent Home is <Agent_Base_Directory>/agent_13.

* If the AgentPatcher directory exists inside the Agent Home, take a backup of it:

  mv <Agent_Home>/AgentPatcher <Agent_Home>/AgentPatcher_old

* Unzip the file inside the Agent Home.

* Export the ORACLE_HOME variable to the Agent Home

  export ORACLE_HOME=<Agent Home>

* Verify the AgentPatcher version by executing:

  $ORACLE_HOME/AgentPatcher/agentpatcher version

2.2 Set the ORACLE_HOME environment variable to agent core home as follows

For standalone agent:


For an agent that ships with the OMS:


2.3 Run the following command to stop the Management Agent

    $ORACLE_HOME/bin/emctl stop agent

2.4 Extract the contents of the patch ZIP file to the stage location (Referred to as <PATCH_TOP_DIR> in the this post) 


2.5 Navigate to the <PATCH_TOP_DIR>/<Patch_Numnber> directory

2.6 Run the following commands to install the patch.

For EM Agent 13.5 RU:

    $ORACLE_HOME/AgentPatcher/agentpatcher apply 

For other patch: 

    $ORACLE_HOME/OPatch/opatch apply

2.7 Start the Management Agent by running the following command:

    $ORACLE_HOME/bin/emctl start agent

Note: If the Management Agent is installed on a cluster, then ensure that you start the Management Agent on all the nodes of the cluster.

No comments: