"problem starting Java virtual machine"

ares09x
ares09x New Altair Community Member
edited November 5 in Community Q&A
Although RapidMiner was working properly on my Windows XP SP3 machine in the past, when I tried to start it recently the Java Virtual Machine Launcher gave the error message "Could not create the Java virtual machine".  I removed and reinstalled the latest version of Java, then I installed the latest version of RapidMiner, 4.6, but I'm still getting that error message. 

I can successfully launch RapidMiner through a .bat file by going to the RapidMiner's lib folder and calling java directly, as in java -Xmx800m -jar rapidminer.jar.  Even though I have 4GB of RAM, I can't go beyond about 800MB, otherwise even the .bat file gives me an object heap error and can't start the Java virtual machine, so it's possible that RapidMiner is trying to use too much memory and that's causing the problem; however, as I said above, version 4.5 used to work just fine.

Any suggestions about how to solve this problem?

Thanks.
Tagged:

Answers

  • land
    land New Altair Community Member
    Hi,
    that seems to be a severe problem. Could you please replace the Java Runtime Environment in the rapidminer/jre directory with the one of 4.5? Perhabs there's some problem in the latest java version with 32 bit windows and 4GB. Unfortunately I have only 2 GB and cannot test it myself...

    Greetings,
      Sebastian
  • spitfire_ch
    spitfire_ch New Altair Community Member
    Hi, I have the exact same problem. Can't start it directly, only via said batch file. I did have the same problem with version 4.6 (not always, though).  I uninstalled 4.6 and installed 5. I reinstalled JAVA which apparently to the java test website is working all right. Still, starting RapidMiner.exe causes the error "Could not create the Java virtual machine".

    I don't know about memory consumption, yet.

    Thanks for looking into this!

    Regards
    Hanspeter
  • spitfire_ch
    spitfire_ch New Altair Community Member
    I tried different parameters and figured out that it only works up to 1154 MB:

    java -Xmx1154m -jar rapidminer.jar

    Anything above, and it won't start anymore. So, I suspect that the Java Virtual Machine cannot use more than 1154 MB of RAM on my machine, but the standard parameters are trying to allocate as much memory as possible - which prevents the JVM from starting (wild speculation).

    The big question that's left is: why can't the JVM not use more of my computers memory? My PC is running WinXP Pro 32 bit with 3 GB RAM. I know that the amount of memory a process can use is restricted in a 32 bit environment, but that limit should be at least 2 GB:
    For 32-bit processes running on a 32-bit machine, the upper limit of the private portion of the process address space is 2 GB. Using the /3 GB Boot.ini switch, 32-bit processes can acquire up to 3 GB of virtual memory. A 32-bit process that is running on a 64-bit machine can acquire up to 4 GB of private virtual memory.
    http://msdn.microsoft.com/en-us/library/ee815713.aspx

    Any ideas on that?

    Thank you and best regards
    Hanspeter
  • IngoRM
    IngoRM New Altair Community Member
    Hi,

    The big question that's left is: why can't the JVM not use more of my computers memory? My PC is running WinXP Pro 32 bit with 3 GB RAM. I know that the amount of memory a process can use is restricted in a 32 bit environment, but that limit should be at least 2 GB:
    Unfortunately not, it is much less (depending on the machine and the OS):

    http://stackoverflow.com/questions/171205/java-maximum-memory-on-windows-xp
    http://sinewalker.wordpress.com/2007/03/04/32-bit-windows-and-jvm-virtual-memory-limit/

    I remember the limit on 32 Bit Windows machines to be about 1.4 Gig and on 32 Bit Linux machines to be about 1.6 Gig during our tests here. Maybe there are some other background programs preventing you to fetch more than the 1.2 Gigabytes you can use on your machine but there is not much space left anyway  :(

    I heard once that there should be some Windows hacks to increase this limit to something like 1.8 Gig on 32 Bit Windows but I never tried and can hardly imagine. As fas as I can see, the only realistic option to use (much) more memoy is a 64 Bit OS plus the 64 Bit version of RapidMiner. On our machines here we use RapidMiner on 32 Gig machines without any problems and in theory there should not be any limit which will be hit soon by hardware  ;D

    Sorry for the bad news. Cheers,
    Ingo
  • spitfire_ch
    spitfire_ch New Altair Community Member
    I see, thanks for your reply. It's not so bad news, at least I know why it crashes.

    So, is it possible that per default Rapidminer tries to assign more memory than the machine can use, and hence causes a "virtual machine cannot start" error? What are the default seetings if one doesn't provide any parameters?

    Cheers
    Hanspeter
  • IngoRM
    IngoRM New Altair Community Member
    Hi,

    at least I would have an idea why a crash could happen on a 32 Bit machine with 3 Gig of memory. Did you use the Windows executable? In that case, the executable calculated the available memory with some Windows routines and uses about 90% of the free memory for initializing the maximum amount of memory used by RapidMiner. If this amount is too large, maybe this causes the problem. But this should of course only happen if the executable is used, not if you define the memory yourself by using the start script (unless you define an amount too large).

    Cheers,
    Ingo
  • spitfire_ch
    spitfire_ch New Altair Community Member
    Yes, I can confirm that. The crash only occurs when I use the windows executable, not when I start rapid miner using a bat-file where I define the parameters myself.

    Cheers,
    Hanspeter