JDK-6193075 : Manual Class Data Sharing not working on Intel Solaris
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 5.0,5.0u6
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: solaris_8,solaris_10
  • CPU: x86
  • Submitted: 2004-11-09
  • Updated: 2012-10-08
  • Resolved: 2005-11-17
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
Other JDK 6
5.0u7Fixed 6 b61Fixed
Related Reports
Duplicate :  
Description
FULL PRODUCT VERSION :
java version "1.5.0"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-b64)
Java HotSpot(TM) Client VM (build 1.5.0-b64, mixed mode, sharing)


FULL OS VERSION :
SunOS con1 5.8 Generic_108529-29 i86pc i386 i86pc

A DESCRIPTION OF THE PROBLEM :
I am running an application with 3 JVM's. I have manually enabled Class Data Sharing using the command java -Xshare:dump. This seems to work fine.

When I start the first JVM with the command line option -Xshare:on it seems to start fine and indicates "sharing" when I print out -showversion.

Then when I start any subsequent JVM's with -Xshare:on AND the -Xmx5m parameter I receive the following error:

An error has occured while processing the shared archive file.
Unable to reserve shared region.
Error occurred during initialization of VM
Unable to use shared archive.

It seems to work fine if I dont set the maximum heap size.

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Try to execute a JVM with class data sharing on, then try it again with class data sharing on, AND trying to set the maximum heap size.

EXPECTED VERSUS ACTUAL BEHAVIOR :
It should still allow CDS.
ERROR MESSAGES/STACK TRACES THAT OCCUR :
An error has occured while processing the shared archive file.
Unable to reserve shared region.
Error occurred during initialization of VM
Unable to use shared archive.


REPRODUCIBILITY :
This bug can be reproduced always.

CUSTOMER SUBMITTED WORKAROUND :
Do not set the maximum heap size. (Which I really need to though).

Cannot make any progress using Java 1.5 until this bug is solved because I have very strict memory requirements which I cant meet without using the -Xmx flag.
###@###.### 2004-11-09 23:47:00 GMT

Comments
WORK AROUND In rare cases, class data sharing may be silently disabled with some heap sizes on Solaris Intel. The workaround is to specify a different maximum heap size using the -Xmx command line option.
08-02-2006

EVALUATION Fixing the first 2 problems mentioned in the comments section. The third will have to wait for a fix to 6204603.
02-11-2005