Jump to content

  • Curse Sites
Become a Premium Member! Help
Latest News Article

Could not create the Java virtual machine.


  • Please log in to reply
95 replies to this topic

#1

dpunch4
    dpunch4

    Tree Puncher

  • Members
  • 10 posts

Posted 19 September 2010 - 03:57 AM

I used search, found A LOT of threads. I tried some things but none worked. I most likely stuffed up somewhere.

Trying to use the downloaded version due to the site being down. I'm using windows xp i think.

Can someone tell me how to fix, with ridiculously easy steps... also my minecraft file isn't a .jar or a .exe  its just minecraft. I'll look at its properties now to see if i'm wrong.

thanks for the help.

Register or log in to remove.

#2

lord_hamani

Posted 19 September 2010 - 08:24 AM

I've got the same problem. Also about the file without extension, but just type ".exe" behind the name, and it'll be an executable file. But I also get the "could not create the java virtual machine" error, and I don't know how to fix it, i've been looking on some sites, but I couldn't find anything usable here. On another topic on this forum I saw that there is no fix, but there has to be one, right?
Posted Image

#3

Xenogard
    Xenogard

    Forum/Wiki Sponsor

  • Curse Premium
  • 487 posts
  • Location: Hell

Posted 19 September 2010 - 08:26 AM

First off I must start by asking, do either of you have java installed on your machines?

Bored? >>>Posted Image<<< Join me


#4

lord_hamani

Posted 19 September 2010 - 08:31 AM

I have Java installed, but when I try to update my PC crashes...
Posted Image

#5

Xenogard
    Xenogard

    Forum/Wiki Sponsor

  • Curse Premium
  • 487 posts
  • Location: Hell

Posted 19 September 2010 - 08:33 AM

I cant really promise anything but I can at least try to help. What are your specs?

Bored? >>>Posted Image<<< Join me


#6

lord_hamani

Posted 19 September 2010 - 08:34 AM

What are specs :(
Posted Image

#7

Xenogard
    Xenogard

    Forum/Wiki Sponsor

  • Curse Premium
  • 487 posts
  • Location: Hell

Posted 19 September 2010 - 08:36 AM

PC specs. like what is your processor speed, how much ram do you have. that kinda stuff.

its very possible that your machine is rather old and cant handle the game. although I couldn't tell you unless i knew the specs

Bored? >>>Posted Image<<< Join me


#8

lord_hamani

Posted 19 September 2010 - 08:39 AM

I wasn't sure so I asked :|:
Windows Vista Home Premium SP 2
Intel Core 2 Duo CPU E4400 2.00 GHz processor
3,00 GB RAM
Posted Image

#9

Xenogard
    Xenogard

    Forum/Wiki Sponsor

  • Curse Premium
  • 487 posts
  • Location: Hell

Posted 19 September 2010 - 08:44 AM

The only thing I could think of to be honest is trying to uninstall then re-install java, then check on their website to make sure its working correctly. other then that I really don't know what the problem could possibly be.

Bored? >>>Posted Image<<< Join me


#10

lord_hamani

Posted 19 September 2010 - 08:49 AM

But I saw a topic on the sun forum about someone who uninstalled Java but he couldn't reinstall it, and someone said the only way to reinstall it was to reinstall windows...
Posted Image

#11

Xenogard
    Xenogard

    Forum/Wiki Sponsor

  • Curse Premium
  • 487 posts
  • Location: Hell

Posted 19 September 2010 - 08:52 AM

lord_hamani said:

But I saw a topic on the sun forum about someone who uninstalled Java but he couldn't reinstall it, and someone said the only way to reinstall it was to reinstall windows...

I dunno, I've never had that happen to me. I just uninstalled it and re-installed it recently and it worked fine for me. But I have a much different set up so that might have a factor in it.

Bored? >>>Posted Image<<< Join me


#12

lord_hamani

Posted 19 September 2010 - 08:57 AM

I'll try some things. Thanks for you help :(
Posted Image

#13

dpunch4
    dpunch4

    Tree Puncher

  • Members
  • 10 posts

Posted 19 September 2010 - 10:52 AM

hours later someone comes to help.. OK

Derp i have java, i recently reinstalled it. jesus christ....

can someone provide help now? thanks in advance

#14

kandelon
    kandelon

    Out of the Water

  • Members
  • 3 posts

Posted 19 September 2010 - 01:28 PM

I've been having the same problem, and may have tracked down the (a?) root cause.

I was getting the popup claiming "Could not create the java virtual machine" when running the .exe file (both versions from the site). So I grabbed the .jar version labeled "linux/other". Since Java is platform independent I figured it should work anyways (the exe was just a nice way for them to package things for Windows). That's how I discovered the following.

When attempting to run with the recommended maximum memory (-Xmx1024M) in the console I immediately get:

Error occurred during initialization of VM
Could not reserve enough space for object heap
Could not create the Java virtual machine.

Note that the last line matches the error we are seeing from the exe, which leads me to believe that it's attempting to set the same memory allocation and failing in this same way. From searching the web, I think I've determined that there is a maximum amount of memory that 32bit Windows (and/or 32bit Java) will allow.

I also tried running with no memory specification, and with the most I could seem to get (around 825M), and I get to the login screen. When I type in my info, I get this error on the command line instead:

java.lang.reflect.InvocationTargetException
		at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
		at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
		at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
		at java.lang.reflect.Constructor.newInstance(Unknown Source)
		at net.minecraft.GameUpdater.extractLZMA(GameUpdater.java:558)
		at net.minecraft.GameUpdater.extractJars(GameUpdater.java:627)
		at net.minecraft.GameUpdater.run(GameUpdater.java:239)
		at net.minecraft.Launcher$1.run(Launcher.java:73)
Caused by: java.lang.OutOfMemoryError: Java heap space
		at LZMA.LzmaInputStream.readHeader(LzmaInputStream.java:277)
		at LZMA.LzmaInputStream.(LzmaInputStream.java:65)
		... 8 more
Fatal error occured (5): null

That last line "about (5): null" also shows up in the game window and looks familiar from some other posts around here as well. In any case, we're running out of memory when attempting to extract (unzip) the lzma files. I don't know much about lzma, but it looks like it's a compression format from 7zip?

Their site claims it to be very efficient on memory usage when decompressing, so I can't figure out why it would need a full GB. Looking in further, the lzma unzipping library minecraft is using seems to be from 2008. There are much more recent versions from this year that presumably are better behaved? Hopefully it's a simple matter of plugging in a new version and providing a 32bit version of the exe that calls for a smaller memory maximum.

For the record:
Windows XP 32bit SP3, Java 1.6.0_21 (most recent), 3GB Ram.

#15

lord_hamani

Posted 20 September 2010 - 01:26 PM

I just got an error like that on my school computer, but I tried it again without my password etc. and I was able to play it.
Posted Image

#16

dpunch4
    dpunch4

    Tree Puncher

  • Members
  • 10 posts

Posted 21 September 2010 - 05:16 PM

cool sites back up. ok so Kandelon is pretty much telling us that we need to wait for a version of minecraft that doesn't fail? can anybody figure out a work-around for this problem? and if you can get a fix, PLEASE explain in a way someone who doesn't know much about computers. I'm not stupid, I just don't know coding and stuff....

GRR I wanna grammar nazi myself but i cbf.

#17

topgearfan1

Posted 21 September 2010 - 08:41 PM

I get the same issue on my computer at my desk but on another much older computer in the office it runs fine. Both computers are XP SP3 with the latest java. I have tried various work arounds like creating a .bat file with a command someone wrote in another forum but no luck there either. It seems to be hitting mostly XP based machines, and random at that. Our tech guy could not figure it out other than the minecraft language is not written properly to work on all aspects of java and that it is really hard to figure java out in the first place. It ran on his windows 7 computer fine as well.

Maybe notch will be able to help out later in future updates.

#18

clpo13
    clpo13

    Forum/Wiki Sponsor

  • Curse Premium
  • Curse Premium
  • 17 posts

Posted 22 September 2010 - 10:46 PM

I had this same exact problem on Windows XP. Here's what I did to get things working:

I downloaded the Linux file Minecraft.jar. I opened the Windows command prompt (Start>Run>cmd), navigated to the directory of Minecraft.jar and typed:

java -Xmx512M -Xms256M -cp Minecraft.jar net.minecraft.LauncherFrame

It's the same code from the download page but with lower memory limits. I don't know how high up it could go before running into memory errors. The game runs fine, even after the login screen, but I don't know if it'll work for everyone.

I did have to delete a couple of the .dlls in the .minecraft\bin\natives folder to get the sound to work. Windows complained about the OpenAL64.dll file (probably because I'm running 32-bit Windows) and wouldn't enable sound in the game unless it wasn't there.
Shiny!

#19

dpunch4
    dpunch4

    Tree Puncher

  • Members
  • 10 posts

Posted 24 September 2010 - 03:31 PM

HOLY COW! not sure how to do what you said but I hope someone explains it to me!!!!

#20

SpongeBob

Posted 24 September 2010 - 03:44 PM

Go to the command prompt and enter "javaw.exe"  (Start->Run->Enter "cmd").  Let me know if the same error message shows up.