United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6627787 CMS: JVM refuses to start up with -Xms16m -Xmx16m
JDK-6627787 : CMS: JVM refuses to start up with -Xms16m -Xmx16m

Details
Type:
Bug
Submit Date:
2007-11-09
Status:
Closed
Updated Date:
2011-04-25
Project Name:
JDK
Resolved Date:
2011-04-25
Component:
hotspot
OS:
generic
Sub-Component:
gc
CPU:
generic
Priority:
P3
Resolution:
Fixed
Affected Versions:
6u4,7
Fixed Versions:
hs21 (b05)

Related Reports
Backport:
Duplicate:
Relates:

Sub Tasks

Description
% /java/re/jdk/7/promoted/all/b02/binaries/solaris-sparc/bin/java -XX:+PrintCommandLineFlags -XX:+UseConcMarkSweepGC -XX:CMSYoungGenPerWorker=4m -Xms16m -Xmx16m -version

-XX:MaxHeapSize=16777216 -XX:+PrintCommandLineFlags -XX:+UseConcMarkSweepGC 
java version "1.7.0-ea"
Java(TM) SE Runtime Environment (build 1.7.0-ea-b02)
Java HotSpot(TM) Server VM (build 1.7.0-ea-b02, mixed mode)

% /java/re/jdk/7/promoted/all/b03/binaries/solaris-sparc/bin/java -XX:+PrintCommandLineFlags -XX:+UseConcMarkSweepGC -Xms16m -Xmx16m -version

-XX:MaxHeapSize=16777216 -XX:+PrintCommandLineFlags -XX:+UseConcMarkSweepGC 
Error occurred during initialization of VM
Incompatible initial and maximum heap sizes specified

But the following is a workaround of sorts:
% /java/re/jdk/7/promoted/all/b03/binaries/solaris-sparc/bin/java -XX:+PrintCommandLineFlags -XX:+UseConcMarkSweepGC -Xms16m -Xmx16m -XX:+CMSUseOldDefaults -version
-XX:+CMSUseOldDefaults -XX:MaxHeapSize=16777216 -XX:+PrintCommandLineFlags -XX:+UseConcMarkSweepGC 
java version "1.7.0-ea"
Java(TM) SE Runtime Environment (build 1.7.0-ea-b03)
Java HotSpot(TM) Server VM (build 1.7.0-ea-b03, mixed mode)

This is a regression as a result of the changes in:

6465357 CMS: default choice of NewSize can cause obscure startup failure w/small -Xms

                                    

Comments
EVALUATION

A malinteraction between ergonomic settings in CMS and sizes explicitly
set at the command-line. Problem manifests at small Xms=Xmx values and
has "easy" workaround. While customers are generally unlikely to run into this
issue, we should fix this at the next available opportunity (HX 11 or 12).
                                     
2007-11-09
EVALUATION

We'll wait for the fixes to 6557851 before making the changes needed to fix this bug.
                                     
2007-11-26
EVALUATION

http://hg.openjdk.java.net/jdk7/hotspot-gc/hotspot/rev/dde920245681
                                     
2011-03-16
EVALUATION

http://hg.openjdk.java.net/jdk7/hotspot-rt/hotspot/rev/dde920245681
                                     
2011-03-21
EVALUATION

http://hg.openjdk.java.net/jdk7/hotspot-comp/hotspot/rev/dde920245681
                                     
2011-03-25



Hardware and Software, Engineered to Work Together