How to increase java memory size and recommended setting for Identity Manager

  • 3732231
  • 23-Jan-2008
  • 05-Jan-2017

Environment

DirXML
Nsure Identity Manager 2.0
Novell Identity Manager 3.0
Novell Identity Manager 3.5
Novell Identity Manager 3.5.1
Novell Identity Manager 3.6
Novell Identity Manager 3.6.1
Novell Cross Platform Services
Novell NetWare 5.1, 6.0, 6.5
Microsoft Windows 2000, 2003, 2008
Linux
Multiple DirXML drivers on machine

Situation

How to set the Java Heap Size
Driver stops for no apparent reason on a server running multiple drivers.
IDM servers sometimes core with this setting set too high
Memory size allocated to Java is not sufficient.
java.io.IOException: Unable to allocate SSL_CTX

Resolution

The Netware option below will set Java to use 256 Megabytes. Normally, you can run IDM with this set to a lower value.
It is recommended that you start with 64M and if still having a problem, increase it to 128M.
The reason to keep it as low as possible is because this setting takes away memory from the eDirectory memory space. Setting the Java setting too high may cause performance or cause eDirectory to run out of memory and core the server.

On NetWare

Note: This is based off of one customer's implementation of eight drivers running on their 6.5 server. Test this solution prior to implementing it in production.

create a Java.cfg file in the sys:\etc directory if it does not already exist.

Include the line"DIRXML_JVM_MAX_HEAP=256M"
This will set Java to use 256 Megabytes. Normally, you can run the driver with this set much lower.
It is recommended that you start with 64M and if still having a problem, increase it to 128M.
The reason to keep it as low as possible is because this setting takes away memory from the eDirectory memory space. Setting the Java setting too high may cause performance or cause eDirectory to run out of memory and core the server.

Use the Java -showmemory(put in the ID number) command to show the memory page

See the online documentation: https://developer.novell.com/ndk/doc/dirxml/dirxmlbk/ref/dirxmlfaq-nw.html

On Windows 2000 / 2003 / 2008

Set the environment variable by following these steps:

1. Select the System icon in the Control Panel.
2. Click on the Advanced tab.
3. Click on Environment Variables.
4. Under 'System Variables' click New.
5. For 'Variable Name' enter DHOST_JVM_MAX_HEAP (must be all capital letters).
6. For 'Variable Value' enter the number of bytes (default is 64000000)
7. Click OK on each dialog until they are closed.

On Solaris

You need to set the environment variables mentioned below.

1. DHOST_JVM_INITIAL_HEAP
2. DHOST_JVM_MAX_HEAP

Set these to the desired value in decimal bytes for initial and max java heap sizes respectively.
The way to set an environment variable would be to type the following on the shell prompt...

$ <environment-variable>=<value>
$ export <environment-variable>

On Linux

**For IDM 4.5, please refer to TID 7000224

Setting the JVM Parameters for DirXML 1.1

Please refer to KB 10065331 for more extensive Java environment options.

You can increase the Native Java Stack Size from 400k to 1-2MB as required by using the "-Xss" parameter. This native stack size is the amount of memory allocated per thread for DirXML.

The following is a clip from a /etc/init.d/ndsd file. This was put in at the top of the file and resolve their dhost abends running DIRXML 1.1 only. (The quotes are required.)

DIRXML 1.1 SETTINGS

########################################
# Variables to allocate heap space for the JVM used for DirXML drivers.
# Make sure NOT to allocate more memory than the system has, or the
# drivers will force a core dump with ndsd.
# This setting only needs to be configured for systems hosting
# DirXML drivers. These settings are in bytes.
#
DHOST_JVM_INITIAL_HEAP=100000000
DHOST_JVM_MAX_HEAP=200000000
DHOST_JVM_OPTIONS="-Xss1m -XX:-UseCompilerSafepoints"
export DHOST_JVM_INITIAL_HEAP DHOST_JVM_MAX_HEAP DHOST_JVM_OPTIONS
#
# End increase DirXML heap size
########################################

Setting the JVM parameters for DirXML 1.1a, NSure Identity Manager 2.x, Novell Identity Manager 3.0.x / 3.5.x / 3.6.x

The following is a clip from a /etc/init.d/ndsd file. This was put in at the top of the file and resolve their dhost abends running DIRXML 1.1a.

DIRXML 1.1a (and later) SETTINGS

########################################
# Variables to allocate heap space for the JVM used for DirXML drivers.
# Make sure NOT to allocate more memory than the system has, or the
# drivers will force a core dump with ndsd.
# This setting only needs to be configured for systems hosting
# DirXML drivers. These settings are in bytes.
#
DHOST_JVM_INITIAL_HEAP=100000000
DHOST_JVM_MAX_HEAP=200000000
DHOST_JVM_OPTIONS=-Xss1m
export DHOST_JVM_INITIAL_HEAP DHOST_JVM_MAX_HEAP DHOST_JVM_OPTIONS
#
# End increase DirXML heap size
########################################

If there is already an export line, the just add the DHOST_JVM_OPTIONS to the end of the that line. Do NOT add another export line to the ndsd file if one already exists.

Also, starting with Novell Identity Manager 3.6.0, the JVM memory settings can be done through Designer or iManager. For instructions please refer to the IDM documentation at https://www.novell.com/documentation .

The link for IDM 3.6.1 docs with the instructions is https://www.novell.com/documentation/idm36/idm_common_driver/data/bg0n8f8.html

Additional Information


Formerly known as TID# 10062098