Feb 9, 2018

Upgrade OEM agent 12c to 13c

Find current agent version before you upgrade on a host:

$ emctl status agent
Oracle Enterprise Manager Cloud Control 12c Release 4 
Copyright (c) 1996, 2014 Oracle Corporation.  All rights reserved.
---------------------------------------------------------------
Agent Version          : 12.1.0.4.0
OMS Version            : 13.2.0.0.0
Protocol Version       : 12.1.0.1.0
Agent Home             : /u01/app/oracle/oem/12c/agent12c/agent_inst
Agent Log Directory    : /u01/app/oracle/oem/12c/agent12c/agent_inst/sysman/log
Agent Binaries         : /u01/app/oracle/oem/12c/agent12c/core/12.1.0.4.0
Agent Process ID       : 35881
Parent Process ID      : 33350
Agent URL              : https://sample01.example.com:3872/emd/main/
Local Agent URL in NAT : https://sample01.example.com:3872/emd/main/
Repository URL         : https://oem13ccloudcontrol:1159/empbs/upload
Started at             : 2018-01-13 12:16:01
Started by user        : oracle
Operating System       : Linux version 2.6.32-358.el6.x86_64 (amd64)
Last Reload            : (none)
Last successful upload                       : 2018-02-08 09:21:12
Last attempted upload                        : 2018-02-08 09:21:12
Total Megabytes of XML files uploaded so far : 53.13
Number of XML files pending upload           : 0
Size of XML files pending upload(MB)         : 0
Available disk space on upload filesystem    : 31.79%
Collection Status                            : Collections enabled
Heartbeat Status                             : Ok
Last attempted heartbeat to OMS              : 2018-02-08 09:21:02
Last successful heartbeat to OMS             : 2018-02-08 09:21:02
Next scheduled heartbeat to OMS              : 2018-02-08 09:22:02

---------------------------------------------------------------
Agent is Running and Ready

$

Now proceed with upgrade process:

Step-1: Connect to your OEM console and follow below steps:

Set up à Manage Cloud Control à Upgrade Agents  


















Then select "+ Add" button to add host(s) to upgrade.




























Like-wise you can add multiple hosts. Remember, in case of RAC databases, give the cluster name, automatically it will discover all the hosts.

After Adding hosts then use "Submit" and then Click "OK" to proceed agent upgrade process. You can see below screen like this after upgrade.


















In the above screen-shot, it is seen agent is upgraded successfully. Next you need to run "root.sh" from the new home in root (#) prompt.

To find new home, now login to target host and check the agent status:

$ emctl status agent
Oracle Enterprise Manager Cloud Control 13c Release 2 
Copyright (c) 1996, 2016 Oracle Corporation.  All rights reserved.
---------------------------------------------------------------
Agent Version          : 13.2.0.0.0
OMS Version            : 13.2.0.0.0
Protocol Version       : 12.1.0.1.0
Agent Home             : /u01/app/oracle/oem/12c/agent12c/agent_inst
Agent Log Directory    : /u01/app/oracle/oem/12c/agent12c/agent_inst/sysman/log
Agent Binaries         : /u01/app/oracle/oem/12c/agent12c/agent_13.2.0.0.0
Core JAR Location      : /u01/app/oracle/oem/12c/agent12c/agent_13.2.0.0.0/jlib
Agent Process ID       : 29870
Parent Process ID      : 6455
Agent URL              : https://sample01.example.com:3872/emd/main/
Local Agent URL in NAT : https://sample01.example.com:3872/emd/main/
Repository URL         : https://oem13ccloudcontrol:1159/empbs/upload
Started at             : 2018-02-08 10:10:03
Started by user        : oracle
Operating System       : Linux version 2.6.32-358.el6.x86_64 (amd64)
Number of Targets      : 24
Last Reload            : (none)
Last successful upload                       : 2018-02-08 10:32:28
Last attempted upload                        : 2018-02-08 10:32:28
Total Megabytes of XML files uploaded so far : 0.4
Number of XML files pending upload           : 0
Size of XML files pending upload(MB)         : 0
Available disk space on upload filesystem    : 27.32%
Collection Status                            : Collections enabled
Heartbeat Status                             : Ok
Last attempted heartbeat to OMS              : 2018-02-08 10:32:14
Last successful heartbeat to OMS             : 2018-02-08 10:32:14
Next scheduled heartbeat to OMS              : 2018-02-08 10:33:14

---------------------------------------------------------------
Agent is Running and Ready
$

Here you can see now agent is running from new 13c home. Go to 13c home location and run root.sh.

Finally, you can set your new home in .profile / .bash_profile like below:

Before:
$ cat .bash_profile|grep agent
export AGENT_HOME=/u01/app/oracle/oem/12c/agent12c/agent_inst
alias agent='unset ORACLE_SID;export ORACLE_HOME=$AGENT_HOME;export PATH=$ORACLE_HOME/bin:/bin:/usr/bin'
$

After:
$ cat .bash_profile|grep agent
export AGENT_HOME=/u01/app/oracle/oem/12c/agent12c/agent_13.2.0.0.0
alias agent='unset ORACLE_SID;export ORACLE_HOME=$AGENT_HOME;export PATH=$ORACLE_HOME/bin:/bin:/usr/bin'



No comments:

Post a Comment

Translate >>