Jump to content

  • Log in with Facebook Log in with Twitter Log In with Google Log In with Steam
  • Sign In
  • Create Account
Photo

Allocate More Memory To Minecraft

minecraft memory memory ram

  • Please log in to reply
72 replies to this topic

#31
mumblerit

mumblerit

    MuttsWorld Extravaganzor

  • Administrators
  • 1,936 posts
  • Players Head: :

    mumblerit

you dont want to run the Minecraft.exe you want to run the jar, its in %appdata%/.minecraft/bin/ if im not mistaken

yQkaVeM.gif


#32
Elliott564

Elliott564

    Pinecone Eater

  • Diplomats
  • PipPipPipPipPipPipPipPipPip
  • 1,259 posts
  • LocationLook behind you.
  • Players Head: :

    Elliott564

Been using this for a long time. I approve
Posted Image
Xbox: Cowz go Moo

I played wayyyyyyy toooo much COD4 i think when im 70 and struggle to remember my kids names, ill still be able to run through the maps.


#33
majorwitty

majorwitty

    Newbie

  • Members
  • Pip
  • 1 posts
  • Players Head: :

    majorwitty

Thought I'd share my success at memory allocation changes with those who are interested.

I was trying various configurations to allocate memory but my command window would open up then immediately close or JVM would not launch, etc.

I have Win7 Ultimate 64-bit, 12 GB RAM, with current version of Java installed.

I created a batch file & updated my PATH variable with directory of current Java version.

Batch file contains (use your own c:\path2minecraft.exe here):
javaw -Xms768m -jar "c:\minecraft\Minecraft.exe"

Added this to PATH (don't forget the semi-colon to separate this path from previous one):
;C:\Program Files (x86)\Java\jre6\bin

For Win7 Ultimate I right click Computer > Properties > Advanced System Settings > Advanced Tab > Environmental Variables > System Variables > highlight PATH then click EDIT. Add semi-colon then PATH to current version of Java then press Okay.

I've read about other people starting minecraft.exe with -Xmx parameter but I could not get various options to work (even though I have 12 GB RAM).

I only changed my memory allocations on this machine due to in-game memory crashes every 90 to 120 seconds of running around outside. Once I allocated 768m I haven't had a memory crash in about 10 hours of game play. This started happening to my machine since 1.7.

The same machine runs minecraft flawless in Fedora Core 15 without memory modifications but Ventrilo support doesn't exist for Linux distributions so I use Windows.

#34
mumblerit

mumblerit

    MuttsWorld Extravaganzor

  • Administrators
  • 1,936 posts
  • Players Head: :

    mumblerit

add pause to end of script it wont close

thats interesting because by default it uses -xms500M

yQkaVeM.gif


#35
Ragnarok

Ragnarok

    Newbie

  • Members
  • Pip
  • 2 posts
  • Players Head: :

    VoidFusion

Okay, this is what I get, when I do this.

Check the attachment.

Any suggestions as to why?

If the attachment doesn't work, go here. http://puu.sh/7Xnj

Attached Thumbnails

  • WTF.png


#36
Double_DeluXe

Double_DeluXe

    Random

  • Server Admin
  • 2,420 posts
  • LocationThe Netherlands
  • Players Head: :

    Double_DeluXe

Oh minecraft! Why thou eat all my memoryz?
WHY?!?!?

I'm just being random, so:
Posted Image

That was awesome Double. You are a god among men.

I love you just so you know <3333 lol :-P


#37
mumblerit

mumblerit

    MuttsWorld Extravaganzor

  • Administrators
  • 1,936 posts
  • Players Head: :

    mumblerit

Okay, this is what I get, when I do this.

Check the attachment.

Any suggestions as to why?

If the attachment doesn't work, go here. http://puu.sh/7Xnj


seems like remove the word java outside the quotes before the -Xms

yQkaVeM.gif


#38
Ragnarok

Ragnarok

    Newbie

  • Members
  • Pip
  • 2 posts
  • Players Head: :

    VoidFusion

seems like remove the word java outside the quotes before the -Xms


Definitely love you right now! (no homo), thank you SO much

#39
Aelfraed

Aelfraed

    Newbie

  • Members
  • Pip
  • 4 posts
  • Players Head: :

    Aelfraed

When I double click on the .bat which is on my Desktop the window for it open briefly and then vanishes so I can't see what it says. I tried the pause at the end and it didn't work. Got any suggestions?

#40
Double_DeluXe

Double_DeluXe

    Random

  • Server Admin
  • 2,420 posts
  • LocationThe Netherlands
  • Players Head: :

    Double_DeluXe

Hit that printscreen button like a boss

I'm just being random, so:
Posted Image

That was awesome Double. You are a god among men.

I love you just so you know <3333 lol :-P


#41
Aelfraed

Aelfraed

    Newbie

  • Members
  • Pip
  • 4 posts
  • Players Head: :

    Aelfraed

No such luck. Am I supposed to leave the script on my desktop or put in a folder in the minecraft folder? Either way it still says I'm using 495 MB for the game.

#42
Gregory Gumpas

Gregory Gumpas

    Newbie

  • Members
  • Pip
  • 1 posts
i get could not create virtual java machine when i do this. ive been trying several different ways and getting the same results . extremely frustrating because ive been dealing with this crashing problem ever since i started playing and havent found a solution that works for me, but this apparently works for everyone but me ..
anyways this is a picture of what happens every 5 mins in minecaft, it just starts halting and freezing up and the ram numbers dont appear to change but it gets those huge spikes..
please help
Posted Image

Thought I'd share my success at memory allocation changes with those who are interested.

I was trying various configurations to allocate memory but my command window would open up then immediately close or JVM would not launch, etc.

I have Win7 Ultimate 64-bit, 12 GB RAM, with current version of Java installed.

I created a batch file & updated my PATH variable with directory of current Java version.

Batch file contains (use your own c:\path2minecraft.exe here):
javaw -Xms768m -jar "c:\minecraft\Minecraft.exe"

Added this to PATH (don't forget the semi-colon to separate this path from previous one):
;C:\Program Files (x86)\Java\jre6\bin

For Win7 Ultimate I right click Computer > Properties > Advanced System Settings > Advanced Tab > Environmental Variables > System Variables > highlight PATH then click EDIT. Add semi-colon then PATH to current version of Java then press Okay.

I've read about other people starting minecraft.exe with -Xmx parameter but I could not get various options to work (even though I have 12 GB RAM).

I only changed my memory allocations on this machine due to in-game memory crashes every 90 to 120 seconds of running around outside. Once I allocated 768m I haven't had a memory crash in about 10 hours of game play. This started happening to my machine since 1.7.

The same machine runs minecraft flawless in Fedora Core 15 without memory modifications but Ventrilo support doesn't exist for Linux distributions so I use Windows.

i love posts like this because they dont explain anything about what they mean they just assume the person reading knows as much about this stuff as them. you changed the PATH variable. ok ill just go do that, then ill do everythign else this post says that makes absolutely no sense to me

the first post in the thread explains how to do what the person is saying in ways that people who arent java wizards can understand and do , step by step... so if this actually works it would be helpful for you to do that

#43
mumblerit

mumblerit

    MuttsWorld Extravaganzor

  • Administrators
  • 1,936 posts
  • Players Head: :

    mumblerit

When I double click on the .bat which is on my Desktop the window for it open briefly and then vanishes so I can't see what it says. I tried the pause at the end and it didn't work. Got any suggestions?


something is very wrong of the pause is not working

One thing people dont understand is that garbage collection is based on cpu as well as ram, which is why the total amount of ram allocated can have different results.

i get could not create virtual java machine when i do this. ive been trying several different ways and getting the same results . extremely frustrating because ive been dealing with this crashing problem ever since i started playing and havent found a solution that works for me, but this apparently works for everyone but me ..
anyways this is a picture of what happens every 5 mins in minecaft, it just starts halting and freezing up and the ram numbers dont appear to change but it gets those huge spikes..
please help
Posted Image


i love posts like this because they dont explain anything about what they mean they just assume the person reading knows as much about this stuff as them. you changed the PATH variable. ok ill just go do that, then ill do everythign else this post says that makes absolutely no sense to me

the first post in the thread explains how to do what the person is saying in ways that people who arent java wizards can understand and do , step by step... so if this actually works it would be helpful for you to do that


we use teamspeak and there is indeed linux teamspeak clients

yQkaVeM.gif


#44
mw94xbox

mw94xbox

    Newbie

  • Members
  • Pip
  • 1 posts
  • Players Head: :

    mw94xbox

i manages to print screen the box before it disappeared, it said that javaw was not recognised... what do i do?
Ok i fixed this but now i get a pop up saying that it couldnt create the virtual machine

Edited by mw94xbox, 01 March 2012 - 09:26 AM.


#45
Sporkflips

Sporkflips

    Newbie

  • Members
  • Pip
  • 1 posts
  • Players Head: :

    Sporkflips

I just made an account on here so that I could post on this topic :P but anyways.. I'm running Windows 7 and it's 32-bit. I followed the instructions and use exactly this:
javaw -Xmx2048m -Xms1024m -jar "%appdata%\.minecraft\bin\Minecraft.jar"
for the text file. I saved it as a batch file and then clicked on it and it says "Could not create the Java Virtual Machine." like I saw some other people got. Before using that, I put
javaw -Xmx2048m -Xms1024m -jar "C:\Users\*************\Desktop\Minecraft.exe"
which is the correct location for Minecraft.exe and I got the same error. I'm not really sure what's wrong. I've searched how to fix the JVM problem but I couldn't seem to find anything helpful. I hope there's a way to fix this as when playing in single player, the game crashes every two minutes saying that it ran out of allocated memory v.v
Sorry if I didn't provide enough information, I'm not like THAT aware of how all this stuff works, I only have mild experience with it.
heh ;D

Edited by Sporkflips, 10 March 2012 - 11:52 AM.


#46
SeargentGen

SeargentGen

    [Derplomat]

  • Diplomats
  • PipPipPipPip
  • 76 posts
  • LocationColorado
  • Players Head: :

    SeargentGen

Just a suggestion:
Instead of doing javaw -Xmx2048m -Xms1024m -jar "C:\<your minecraft directory\Minecraft.exe";
I reccommend replacing the -Xms1024 with -Xincgc. This allows the minecraft application to use as much memory as it wants, until it reaches two gigabytes. This prevents many bugs/crashes. I am pretty sure it works on most computers; it works on my windows 7 64 bit, 8 gig.

Edited by SeargentGen, 19 March 2012 - 05:03 PM.

Posted Image

Posted Image

#47
SeargentGen

SeargentGen

    [Derplomat]

  • Diplomats
  • PipPipPipPip
  • 76 posts
  • LocationColorado
  • Players Head: :

    SeargentGen

Guys who get the "Cannot create java virtual machine" error:

This error is usually caused by more memory being allocated to run minecraft than what is available, or you are using more than 1.5 gigabytes on a 32-bit Java. I'd first making sure you aren't allocated more memory than what exists to the minecraft, and if that doesn't work, upgrade to a 64-bit Java(I recommend Java 7). Also, read my other post about switching to xincgc, which fixes many of the glitches some of you are also experiencing. If you have any questions, I am usually on teamspeak.
Posted Image

Posted Image

#48
JamesChism

JamesChism

    Newbie

  • Members
  • Pip
  • 2 posts
Hello, I am also having some problems with this. I have been reading, and I keep getting an error. It may just be my eyes, but I can't see any problems with my batch file or anything else. Here is my error message:

Posted Image

Here is my batch file text:

Posted Image

#49
CrimsonFlamez

CrimsonFlamez

    Zebra

  • Diplomats
  • PipPipPipPip
  • 61 posts
  • LocationMichigan
  • Players Head: :

    CrimsonFlamez

I suggest double checking the file path of MineCraft.exe. That would explain why it can't find your jar.

Otherwise, it looks correct.

#50
JamesChism

JamesChism

    Newbie

  • Members
  • Pip
  • 2 posts

I suggest double checking the file path of MineCraft.exe. That would explain why it can't find your jar. Otherwise, it looks correct.


The file path is correct. I guess it's just not going to work. Bummer.

#51
Double_DeluXe

Double_DeluXe

    Random

  • Server Admin
  • 2,420 posts
  • LocationThe Netherlands
  • Players Head: :

    Double_DeluXe

I suggest »double« checking the file path of MineCraft.exe.

[lulz] I hacked in your computer and checked the file path, it seems.ok[/lulz]

Now serious:
Try opening a new notepad and type it over instead of just copy/paste.
Even though some characters like a minus "-" or a dot "." seem the same, they can be different per language typed in.

It doesn't make any sence, but it has solved problems like this before :o

I'm just being random, so:
Posted Image

That was awesome Double. You are a god among men.

I love you just so you know <3333 lol :-P


#52
Danielson

Danielson

    Newbie

  • Members
  • Pip
  • 1 posts
  • Players Head: :

    Danielson

Hey all.

I have the same error like: JamesChism and i dont know what to do. . . :(
Bat: javaw -Xmx2048m -Xms1024m -jar "C:\Users\Thexan\Desktop\Minecraft.exe"
Pic: Posted Image

If i put the bat file on desktop the same error, if i choose -Xincgc the same error.

Can you pls help me samehow?

I have Skype Xfire so pls tell me.

Thanks.

Edited by Danielson, 06 April 2012 - 04:27 AM.


#53
npgilbertson

npgilbertson

    Newbie

  • Members
  • Pip
  • 1 posts
  • Players Head: :

    npgilbertson

ARE YOU GOD? This worked, and i have tried EVERYTHING i could find, until this i could not play my technic pack for more than 2 minutes, and that was really bad since it took 5 just to load!

How much money do you want?

I wish i had that much to give you!!!!

:-P :-P :-P

#54
FatPat

FatPat

    Newbie

  • Members
  • Pip
  • 1 posts
i am running an Alienware m15x laptop with 64-bit windows 7. i have 6G of RAM and i have tried many of the things above. sometimes the .bat file i would make would open the command promt and close it instantly, and other times i would open it an it would say "Unable to access jarfile C:\<your minecraft directory\Minecraft.exe" i am kinda confused as to what i'm doing in detail but i have an overall idea.

#55
Double_DeluXe

Double_DeluXe

    Random

  • Server Admin
  • 2,420 posts
  • LocationThe Netherlands
  • Players Head: :

    Double_DeluXe

i am running an Alienware m15x laptop with 64-bit windows 7. i have 6G of RAM and i have tried many of the things above. sometimes the .bat file i would make would open the command promt and close it instantly, and other times i would open it an it would say "Unable to access jarfile C:\<your minecraft directory\Minecraft.exe" i am kinda confused as to what i'm doing in detail but i have an overall idea.

You have to fill in the path to your minecraft directory yourself.
./epicfail

I'm just being random, so:
Posted Image

That was awesome Double. You are a god among men.

I love you just so you know <3333 lol :-P


#56
Mujolot

Mujolot

    Newbie

  • Members
  • Pip
  • 9 posts
  • Players Head: :

    Mujolot

what about mac

What about on the mac?

#57
supraboy97

supraboy97

    Bacon

  • Diplomats
  • PipPipPipPipPipPipPip
  • 322 posts
  • LocationParadise City
  • Players Head: :

    supraboy97

this worked for my mac

http://www.nextgenup...ecraft-mac.html

Edited by supraboy97, 18 May 2012 - 02:30 PM.

Waffles (#)(#)

#58
Rez

Rez

    Baked to Serve

  • Diplomats
  • PipPipPipPipPipPip
  • 146 posts
  • Players Head: :

    Rezzy1

This is a giant mess of a thread but I got it to work eventually.
The whole purpose of buying the boat in the first place is to get the ladies nice and tipsy top-side, so we can take them to a nice comfortable place below deck and..you know...they can't refuse. Because of the implication. - It's Always Sunny in Philadelphia

#59
moonra

moonra

    Newbie

  • Members
  • Pip
  • 1 posts
I'm getting a "Invalid or corrupt jarfile" ):

#60
lengi123

lengi123

    Newbie

  • Members
  • Pip
  • 1 posts
Do i have to double click the .bat file every time i want minecraft to run with my chosen amount of allocated memory?





Similar Topics Collapse