Changing the heap size of Enterprise Manager 12c

Enterprise Manager 12c is a product that is being deployed a lot lately, a vast improvement over previews version. For most DBA’s it is a tool they use regularly on a daily basis so performance is key. Fortunately oracle provides us with some documentation on how to size the repository database and heap size of the Oracle Management Service. An excellent white paper on EM12c sizing can be found here on OTN:

http://www.oracle.com/technetwork/oem/framework-infra/em12c-sizing-1590739.pdf

Interestingly enough it states that Oracle considers installation with +1000 targets as a medium sized em12c environment. That limit of +1000 targets is reached quite easily. One of the advisories is that for a medium EM12c environment the minimum heap size should be at least 4G, most default installation run with a heap size of around 1.5G.

So how do we change the heap size of OMS to 4G, meet the startEMServer.sh script, this script can be located Grid Control domain directory of Weblogic:

[oracle@em12c ~]$ cd `cat ./bea/beahomelist|cut -d\; -f2`/gc_inst/user_projects/domains/GCDomain/bin
if [ "${SERVER_NAME}" != "EMGC_ADMINSERVER" ] ; then
  USER_MEM_ARGS="-Xms2048m -Xmx4096m -XX:MaxPermSize=1500M -XX:-DoEscapeAnalysis -XX:+UseCodeCacheFlushing -XX:ReservedCodeCacheSize=100M -XX:+UseConcMarkSweepGC -XX:+UseParNewGC -XX:+CMSClassUnloadingEnabled"
  if [ "${JAVA_VENDOR}" = "Sun" ] ; then
    if [ "${PRODUCTION_MODE}" = "" ] ; then
      USER_MEM_ARGS="-Xms2048m -Xmx4096m -XX:MaxPermSize=1500M -XX:-DoEscapeAnalysis -XX:+UseCodeCacheFlushing -XX:ReservedCodeCacheSize=100M -XX:+UseConcMarkSweepGC -XX:+UseParNewGC -XX:+CMSClassUnloadingEnabled -XX:CompileThreshold=8000 -XX:PermSize=128m"
    fi
  fi
  export USER_MEM_ARGS
fi

Change the Xms and Xmx parameters on line 2 and 5 the desired values, in this example i choose to set a maximum heapsize of 4G and minimun if 2G. No smart caclculations are done to determine these values, except the upper limit, which came from the earlier mentioned white paper.

[oracle@ovmem01 bin]$ . ./setDomainEnv.sh
[oracle@ovmem01 ~]$ $OMS_HOME/bin/emctl status oms
Oracle Enterprise Manager Cloud Control 12c Release 2
Copyright (c) 1996, 2012 Oracle Corporation.  All rights reserved.
WebTier is Up
Oracle Management Server is Up
[oracle@ovmem01 ~]$ $OMS_HOME/bin/emctl stop oms
Oracle Enterprise Manager Cloud Control 12c Release 2
Copyright (c) 1996, 2012 Oracle Corporation.  All rights reserved.
Stopping WebTier...
WebTier Successfully Stopped
Stopping Oracle Management Server...
Oracle Management Server Successfully Stopped
Oracle Management Server is Down
[oracle@ovmem01 ~]$ $OMS_HOME/bin/emctl start oms
Oracle Enterprise Manager Cloud Control 12c Release 2
Copyright (c) 1996, 2012 Oracle Corporation.  All rights reserved.
Starting Oracle Management Server...
Starting WebTier...
WebTier Successfully Started
Oracle Management Server Successfully Started
Oracle Management Server is Up
[oracle@ovmem01 ~]$

That is about it about changing your heap size for EM12c, short but hopefully interesting post.

About these ads

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s