IBM Support

IBM Technology for Java GC Policy Options within WebSphere Application Server

Question & Answer


Question

Customers are trying to determine which GC policy is in place for their WebSphere Application Server.

Cause

The GC Policy options are not blatantly available and many customers don't know there are choices

Answer

The GC (Garbage Collection) policy in place can be determined by looking at the Generic JVM arguments section of the particular server instance. If the Generic arguments section is blank then the default policy of gencon is selected.

To check the current settings using the WebSphere Integrated Solutions Console:


Servers > Server Types > WebSphere Application servers > <ServerName> > Process definition > Java Virtual Machine





Here is an example of a non default policy in place

The policy can also be identified by using the IBM i WRKJVMJOB command:

1) Issue the WRKJVMJOB

2) Locate your WebSphere Application Server

3) 9=Display GC information

4) Page down

Example screen shot:


The options for Policies are:


Garbage collection policy options

The -Xgcpolicy options control the behavior of the Garbage Collector. There are a number of changes to garbage collection options.

The changes to the garbage collection options are:


-Xgcpolicy:gencon
This option is now the default for garbage collection. The policy requests the combined use of concurrent and generational garbage collection to help minimize the time that is spent in any garbage collection pause.
-Xgcpolicy:optthruput
This option is no longer the default for garbage collection. The policy delivers high throughput to applications, but at the cost of occasional pauses.
-Xgcpolicy:subpool
This option is deprecated and is now an alias for optthruput. Therefore, if you use this option, the effect is the same as optthruput.
-Xgcpolicy:balanced
The balanced garbage collection policy is new. This policy uses a region-based layout for the Java heap. These regions are individually managed to reduce the maximum pause time on large heaps and increase the efficiency of garbage collection. The policy also uses a different object allocation strategy that improves application throughput on large systems that have Non-Uniform Memory Architecture (NUMA) characteristics. (x86 and POWER® platforms only) For more information about this policy, see Balanced Garbage Collection policy.

To change the WebSphere Application Server Garbage Collection policy enter enter a option above as a Generic JVM Argument then restart the server.

[{"Product":{"code":"SWG60","label":"IBM i"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Component":"Java","Platform":[{"code":"PF012","label":"IBM i"}],"Version":"Version Independent","Edition":"All Editions;WAS v9.0;WAS v8.5.5;WAS v8.0;WAS v7.0","Line of Business":{"code":"LOB57","label":"Power"}}]

Document Information

Modified date:
18 December 2019

UID

nas8N1019924