Uploaded image for project: 'Core ReactOS'
  1. Core ReactOS
  2. CORE-4211

Java fails with Class Data Sharing

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Major
    • None
    • Win32SS
    • None
    • Operating System: ReactOS
      Platform: x86 Hardware

    Description

      I tried running Java and got the following error:

      java.exe Application Error
      The instruction at "0x6d8ba31a" referenced memory at "0x00000040". The memory could not be "read".

      The ReactOS SVN revision I built was 41171.
      Using Virtualbox 2.2.2 r46594

      Steps to reproduce, on a 'clean install' of ReactOS:
      1. Download the JDK 1.6 installer, e.g. jdk-6u13-windows-i586-p.exe from http://java.sun.com/javase/downloads/index.jsp
      2. Double click on the installer. A bunch of incomplete screens appear but clicking on the forward arrows to advance the wizard does in fact install the software. Click Finish!
      3. Open a command line.
      4. enter 'java -version'. The first time, the JVM will output the version information, as expected.
      5. enter 'java -version' again. The above error message appears.

      I wondered why it would work the first time but not subsequently, it turns out Java's Hotspot virtual machine loads java classes into shared memory as described here:

      http://java.sun.com/javase/6/docs/technotes/guides/vm/class-data-sharing.html

      launching java as above with the -Xshare:off option as specified in the docs prevents the error message, on a per invocation basis. I'm not aware it's possible to turn it off permanently as a workaround to this bug... Further executing 'java -Xshare:dump' does clear the memory sharing, allowing the first invocation to work as in Step 4.

      Attachments

        Issue Links

          Activity

            People

              bug zilla Bug Zilla
              petec petec
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: