Setting the process memory settings for IPSA upgrade scripts (Doc ID 1371566.1)

Last updated on AUGUST 31, 2016

Applies to:

Oracle Communications IP Service Activator - Version 5.2.4 and later
Information in this document applies to any platform.

Symptoms

When running the tools used to upgrade IPSA the default values may not be sufficient. For example when running the npSnapshot tool we may see the following types of error:

$ npSnapshot.sh
  Starting with 512 MB memory per process.
  Starting with 1 processes.
  Process 0>Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
  Process 0> at sun.nio.cs.StreamEncoder.write(Unknown Source)

 

$ ./npSnapshot.sh
Starting with 512 MB memory per process.
Starting with 1 processes.
Process 0>Exception in thread "main" java.lang.OutOfMemoryError: PermGenspace
Process 0> at java.lang.ClassLoader.defineClass1(Native Method)
Process 0> at java.lang.ClassLoader.defineClass(Unknown Source)
Process 0> at java.security.SecureClassLoader.defineClass(Unknown Source)
Process 0> at java.net.URLClassLoader.defineClass(Unknown Source)
Process 0> at java.net.URLClassLoader.access$000(Unknown Source)
Process 0> at java.net.URLClassLoader$1.run(Unknown Source)
Process 0> at java.security.AccessController.doPrivileged(Native Method)
Process 0> at java.net.URLClassLoader.findClass(Unknown Source)
Process 0> at java.lang.ClassLoader.loadClass(Unknown Source)
Process 0> at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)

 

Although this is obviously a java (JVM) out of memory setting, just adding a -Xmx setting into the execution line does not work:

exec "${JAVA_HOME}/bin/java" -Xmx2048m -server -Duser.timezone=UTC -classpath "${CORE_CP}:${CART_CP}:${CONFIG_POLICY_CP}" -Djava.endorsed.dirs="${JAVA_LIB}/jaxp-1.3" com.metasolv.serviceactivator.upgradetool.SnapshotProcessManager


The same situation will occur when using the npUpgrade tool

-bash-3.00$ ./npUpgrade.sh -all
Starting with 512 MB memory per process.
Starting with 2 processes.
Process 1>Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
Process 1>      at net.sf.saxon.om.FastStringBuffer.ensureCapacity(FastStringBuffer.java:365)
Process 1>      at net.sf.saxon.om.FastStringBuffer.append(FastStringBuffer.java:112)
Process 1>      at net.sf.saxon.query.QueryReader.readQueryFromReader(QueryReader.java:155)
Process 1>      at net.sf.saxon.query.QueryReader.readInputStream(QueryReader.java:96)
Process 1>      at net.sf.saxon.query.QueryReader.readSourceQuery(QueryReader.java:41)
Process 1>      at net.sf.saxon.query.QueryParser.applyModuleImport(QueryParser.java:1030)
Process 1>      at net.sf.saxon.query.QueryParser.processPreamble(QueryParser.java:625)
Process 1>      at net.sf.saxon.query.QueryParser.parseProlog(QueryParser.java:520)
Process 1>      at net.sf.saxon.query.QueryParser.parseQuery(QueryParser.java:248)
Process 1>      at net.sf.saxon.query.QueryParser.makeXQueryExpression(QueryParser.java:101)
Process 1>      at net.sf.saxon.query.StaticQueryContext.compileQuery(StaticQueryContext.java:472)
Process 1>      at net.sf.saxon.query.StaticQueryContext.compileQuery(StaticQueryContext.java:502)
Process 1>      at com.metasolv.serviceactivator.util.XQueryTransformer.<init>(XQueryTransformer.java:83)
Process 1>      at com.metasolv.serviceactivator.util.XQueryTransformer.create(XQueryTransformer.java:51)

Changes

Upgrading IPSA5.2.3 to 5.2.4.

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms