Command Line Install of OEM agent

In this document we will go over the steps to Install OEM agent using command line.

12c:

Download emcli kit from OEM console.

Logon to OEM console.

On the top right Setup –> CommandLine Interface

CLI Download

CLI Download screen

Export JAVA_HOME

[oracle@host emcli]$ export JAVA_HOME=/u01/software/wls1036/jdk1.6.0_45

Install emcli

[oracle@host emcli]$ $JAVA_HOME/bin/java -jar emclikit.jar client -install_dir=/u01/software/emcli

Condifure emcli to OEM

[oracle@host emcli]$ ./emcli setup -url=https://xyzhost:7801/em -username=sysman -trustall

Oracle Enterprise Manager 12c 3.

Copyright (c) 1996, 2013 Oracle Corporation and/or its affiliates. All rights reserved.

 

Enter password

 

Emcli setup successful

[oracle@host emcli]$ ./emcli sync

Synchronized successfully

List the agents that are available. If agent is not available for the platform make sure you download the agent using OEM console.

[oracle@host emcli]$ ./emcli get_supported_platforms

———————————————–

Version = 12.1.0.3.0

Platform = Linux x86-64

———————————————–

Platforms list displayed successfully.

 

Build the image

[oracle@host emcli]$ ./emcli get_agentimage -destination=/u01/Installers/agentinstall -platform=”Linux x86-64″ -version=12.1.0.3.0

=== Partition Detail ===

………………..

Agent Image Download completed successfully.

[oracle@host emcli]$ cd /u01/Installers/agentinstall/

[oracle@host agentinstall]$ ls -ltr

total 240760

-rw-rw-r– 1 oracle oracle 246292296 Jul 29 10:53 12.1.0.3.0_AgentCore_226.zip

 

Copy the agent to the host where you want to deploy the agent and unzip it.

[oracle@host agentinstall]$ unzip -q 12.1.0.3.0_AgentCore_226.zip

[oracle@host agentinstall]$ ls -ltr

total 481636

-rw-rw-r– 1 oracle oracle       178 Jun 22 00:52 agentimage.properties

-rwxr-xr-x 1 oracle oracle    145976 Jun 22 00:53 unzip

-rwxrwxr-x 1 oracle oracle      3775 Jun 22 00:53 agent.rsp

-rwxrwxr-x 1 oracle oracle     23848 Jun 22 00:53 agentDeploy.sh

-rw-rw-r– 1 oracle oracle 239306392 Jun 22 00:53 agentcoreimage.zip

-rw-rw-r– 1 oracle oracle   6906203 Jul 29 10:53 12.1.0.3.0_PluginsOneoffs_226.zip

-rw-rw-r– 1 oracle oracle 246292296 Jul 29 10:53 12.1.0.3.0_AgentCore_226.zip

Modify agent response file.

[oracle@host agentinstall]$ vi agent.rsp

Make changes to the script to add the following properties

[oracle@host agentinstall]$ grep -v \# agent.rsp

RESPONSEFILE_VERSION=2.2.1.0.0

OMS_HOST=xyzhost.us.oracle.com

EM_UPLOAD_PORT=4901

AGENT_REGISTRATION_PASSWORD=xxxxxx

AGENT_PORT=3872

b_startAgent=true

EM_INSTALL_TYPE=”AGENT”

 

 

[oracle@host agentinstall]$ ./agentDeploy.sh AGENT_BASE_DIR=/u01/em12cr3agent RESPONSE_FILE=/u01/Installers/agentinstall/agent.rsp INVENTORY_LOCATION=/home/oracle/agentoraInventory

……….

Agent deployment completed successfully.

 

Make sure root.sh is executed after the install.

 

13c:

Download emcli kit from OEM console.

Logon to OEM console.

On the top right Setup –> CommandLine Interface

Download JDK 7 from My Oracle Support (1.7_171+), unless you are running on the same host as OMS, in which case use the default Java 7 used for OMS (<ORACLE_HOME >/oracle_common/jdk).

Export JAVA_HOME

[oracle@host emcli]$ export JAVA_HOME=/u01/app/jdk1.7.0_191

Install emcli

[oracle@host emcli]$ $JAVA_HOME/bin/java -jar emclikit.jar client -install_dir=/u01/software/emcli

Configure emcli to OEM

[oracle@host emcli]$ ./emcli setup -url=https://xyzhost:7801/em -username=sysman -trustall

 

Oracle Enterprise Manager 13c Release 3.

Copyright (c) 1996, 2018 Oracle Corporation and/or its affiliates. All rights reserved.

 

Enter password

 

Emcli setup successful

[oracle@host emcli]$

 

List the agents that are available. If agent is not available for the platform, make sure you download the agent using OEM console.

[oracle@babusandbox emcli]$ ./emcli get_supported_platforms

———————————————–

Version = 13.3.0.0.0

Platform = Linux x86-64

———————————————–

Platforms list displayed successfully.

 

Build the image

[oracle@host emcli]$ ./emcli get_agentimage -destination=/u01/Installers/agentinstall -platform=”Linux x86-64″ -version=13.3.0.0.0

 

=== Partition Detail ===

…………..

Agent Image Download completed successfully.

 

[oracle@host emcli]$ cd /u01/Installers/agentinstall/

 

[oracle@host agentinstall]$ ls -ltr

total 739980

-rw-rw-r–. 1 oracle oracle 757738435 Jan 30 16:20 13.3.0.0.0_AgentCore_226.zip

 

Copy the agent to the host where you want to deploy the agent and unzip it.

[oracle@host agentinstall]$ unzip -q 13.3.0.0.0_AgentCore_226.zip

[oracle@host agentinstall]$ ls -ltr

total 1462344

-rwxr-xr-x. 1 oracle oracle 739219886 Jun 14  2018 agentcore.bin

-r-xr-xr-x. 1 oracle oracle    230027 Jun 14  2018 zip

-r-xr-xr-x. 1 oracle oracle    145976 Jun 14  2018 unzip

-rw——-. 1 oracle oracle      4161 Jun 14  2018 agent.rsp

-rw-rw-r–. 1 oracle oracle       179 Jun 14  2018 agentimage.properties

-rwxr-xr-x. 1 oracle oracle     76537 Jun 14  2018 agentDeploy.sh

-rwxr-xr-x. 1 oracle oracle       274 Jan 30 16:20 plugins.txt

drwxr-xr-x. 2 oracle oracle      4096 Jan 30 16:20 plugins

-rw-rw-r–. 1 oracle oracle 757738435 Jan 30 16:20 13.3.0.0.0_AgentCore_226.zip

 

Modify agent response file. After making changes the following parameters should be configured.

[oracle@host agentinstall]$ grep -v \# agent.rsp

OMS_HOST= xyzhost.oraclevcn.com

EM_UPLOAD_PORT=4901

AGENT_REGISTRATION_PASSWORD= xxxxxx

b_startAgent=true

AGENT_BASE_DIR=/u01/app/oemagent

AGENT_PORT=3872

EM_INSTALL_TYPE=”AGENT”

 

[oracle@host agentinstall]$ ./agentDeploy.sh RESPONSE_FILE=/u01/Installers/agentinstall/agent.rsp

 

inflated: ………………

patches exist in /u01/app/oemagent/agent_13.3.0.0.0

Applying opatch for the oneoffs p25237184_121300_Generic,24470104 …

…………

** Agent Port Check completed successfully.**

…………

Agent Configuration completed successfully

Waiting for agent targets to get promoted…

Successfully Promoted agent and its related targets to Management Agent

 

Make sure root.sh is executed after the install.

Add Your Comment