Jump to content

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

[Tutorial] Allocate more memory for minecraft

tutorial memory

  • Please log in to reply
353 replies to this topic

#1

Gnampf
    Gnampf

    Coal Miner

  • Members
  • 141 posts
  • Location: Germany

Posted 02 August 2012 - 01:59 PM

*
POPULAR

How to allocate more memory for Minecraft:
Because many people ask this question here's a little tutorial how to give Minecraft more RAM memory to work.


Why should I allocate more memory?:
Normaly Minecraft works fine with his 1GB RAM. But if you allocatte more memory, you can better some situations:
  • More RAM for texture pack buffering (128x ++)
  • More RAM for singleplayer and multiplayer maps buffering (less reloading)
  • Better working with RAM intensive mods
  • Faster map rebuild
First notice:
This tutorial requires that you've installed a full Java version, (Java SE / DK), and a Java Runtime Environment on your system. Else it might not work right. Installing the right Java version (also important: 32/64 bit) often solves many problems.
"Minecraft runs out of memory" happens often while running it with the wrong Java version! The preinstalled Java on new Computers-Systems might not support this.
If you don't have installed Java, get it here!


What do I have to do:

NEW launcher:

Since Minecraft version 1.6.X you can use the new launcher. With this, it is possible to integrate Java commands directly into the game. Here is what you have to do:
  • Download and execute the new launcher
  • In the section "Profile Selection" click on "Edit Profile"
  • Under "Java Settings (Advanced), activate "JVM Arguments" and add into the text area this argument:
    -Xmx2048M -Xms2048M
  • Save this profile and execute Minecraft. You will always start with 2GB of RAM
Need more ram? You can adapt the number to your needings (see RAM Versions)

Posted Image
Picture depending on the launcher version. It may look little different with a newer launcher


OLD launcher:
Spoiler:

Which numbers can I insert?:
Spoiler:


How much space can I allocate?:

At least not more than you've installed in your system.
To see how much RAM is free, open the Task Manager and change to the Performance Tab. Look how much Physical Memory is available / free.
Note that other programs (such as Winamp or Fraps) also need free RAM to work.



Something doesn't work? Possible solutions:
First of all check your batch file on spelling mistakes. This is one of the most frequently faults.
Then be sure you've installed a full Java version! Pre-installed versions might not support more memory.

Other solutions for old launcher:
Spoiler:



You found a fault in the post? Something is missing? Tell it to me!
Please post questions and suggestions in this topic and not via PM!

P.S. Thank you for the positive reputations. Posted Image

Edited by Gnampf, 27 March 2014 - 06:30 PM.

Posted Image

Register or log in to remove.

#2

jimmytrouser

Posted 04 August 2012 - 04:40 PM

Thanks for posting this.
Posted Image

#3

Animal262

Posted 04 August 2012 - 07:48 PM

Followed the steps and it changed to a windows batch file. when i run it, it opens a cmd box for a sec then closes without starting the game.

running windows 7 and the minecraft.exe file is in the same folder and called the same. any help?

#4

Cat_With_Hat

Posted 04 August 2012 - 08:07 PM

View PostAnimal262, on 04 August 2012 - 07:48 PM, said:

Followed the steps and it changed to a windows batch file. when i run it, it opens a cmd box for a sec then closes without starting the game.

running windows 7 and the minecraft.exe file is in the same folder and called the same. any help?
I am having the same exact issue. It worked fine yesterday, and stopped working today.

#5

Gnampf
    Gnampf

    Coal Miner

  • Members
  • 141 posts
  • Location: Germany

Posted 05 August 2012 - 06:08 AM

There are 2 possible problems i thing could make this problem:
1. CMD can't find Minecraft.exe and stops running. You might try to give the whole path.
2. CMD may stop because of administration mode.
Posted Image

#6

Animal262

Posted 05 August 2012 - 01:46 PM

View PostGnampf, on 05 August 2012 - 06:08 AM, said:

There are 2 possible problems i thing could make this problem:
1. CMD can't find Minecraft.exe and stops running. You might try to give the whole path.

Thanks this worked. I changed the bat back to a txt, changed 'minecraft.exe' to full path name 'c:/....minecraft.exe' and it has incresed the ram in game.

#7

CardiacArrest
  • Minecraft: IAMHAZCAIK

Posted 05 August 2012 - 05:41 PM

Doesn't seem to work for me. Here's exactly what I put: java -Xmx2048M -Xms2048M -jar "C:\Users\^^^^^\Desktop\Minecraft.exe" (erased my name) I do have the required RAM, but it just flickers the cmd screen, then nothing happens. Sorry if I'm missing something totally obvious, bit of a noob with this kind of stuff.
Posted Image

#8

Animal262

Posted 05 August 2012 - 10:38 PM

no that looks ok, i typed

java -Xmx3072M -Xms3072M -jar "C:\Users\Russ\Desktop\Minecraft\Minecraft.exe"

(3gig) Mine is in a folder on my desktop and it is the actual application not a shortcut, just check the file, file path spelling

#9

CardiacArrest
  • Minecraft: IAMHAZCAIK

Posted 05 August 2012 - 10:50 PM

I've tried about 10 other variations, but I'll try it once more I guess.

Same thing. Might be something with my computer, it's pretty new, and I'm sure there's nothing wrong with the actual .bat file.
Posted Image

#10

Gnampf
    Gnampf

    Coal Miner

  • Members
  • 141 posts
  • Location: Germany

Posted 06 August 2012 - 05:48 AM

The difficult thing is: before cmd closes, he writes his problem, but then it closes a bit too fast Posted Image .
If we knew what cmd wants to tell us, it would be easier to help. The only think I could tell now is the same like Animal: Be sure the path is spelled right and you have the Minecraft.exe file on your deskop (not a minecraft.ink link).

Try to look if you can capture a picture or something of the cmd. If you find "Error: Unable to acess jarfile Minecraft.exe" then the problem is that cmd doesn't find the file.
Posted Image

#11

Syfaro
    Syfaro

    Retired Guru

  • Retired Staff
  • 5209 posts
  • Minecraft: Syfaro

Posted 06 August 2012 - 05:51 AM

Throw in pause on a new line, that way it will only close after you hit enter.

Minecraft API - A JSON API for fetching information about Minecraft & Minecraft servers

Read my blog about tech stuff!


#12

CardiacArrest
  • Minecraft: IAMHAZCAIK

Posted 06 August 2012 - 10:42 AM

View PostSyfaro, on 06 August 2012 - 05:51 AM, said:

Throw in pause on a new line, that way it will only close after you hit enter.
Thanks! The cmd said that java is not recognized as an internal or external command, operable program or batch file. I might try to update java, although I literally just got the newest pdate.
Posted Image

#13

CardiacArrest
  • Minecraft: IAMHAZCAIK

Posted 06 August 2012 - 10:55 AM

Should I remove java from the beginning? Sorry I'm asking so many questions, but my minecraft really needs more RAM.
Posted Image

#14

CardiacArrest
  • Minecraft: IAMHAZCAIK

Posted 06 August 2012 - 11:16 AM

Spoiler:
Here's a pic of the cmd screen, if it helps any.
Posted Image

#15

Gnampf
    Gnampf

    Coal Miner

  • Members
  • 141 posts
  • Location: Germany

Posted 06 August 2012 - 04:14 PM

Well, I think I know why:
You have annother version of Java than the most other people. For example a 32bit version installed.

Possible Solution:
Install this:

http://www.oracle.co...oad-432154.html
(You said you have a new computer, I think you should download the 64bit version)

There could also be annother reason, but I think what you need is this link Posted Image
I hope this would help.
Posted Image

#16

CardiacArrest
  • Minecraft: IAMHAZCAIK

Posted 06 August 2012 - 04:47 PM

View PostGnampf, on 06 August 2012 - 04:14 PM, said:

Well, I think I know why:
You have annother version of Java than the most other people. For example a 32bit version installed.

Possible Solution:
Install this:

http://www.oracle.co...oad-432154.html
(You said you have a new computer, I think you should download the 64bit version)

There could also be annother reason, but I think what you need is this link Posted Image
I hope this would help.
Thanks! (again) I did get 64 bit origainally, but I"m not sure if I got 32 when I re-installed.
Posted Image

#17

Gnampf
    Gnampf

    Coal Miner

  • Members
  • 141 posts
  • Location: Germany

Posted 06 August 2012 - 05:27 PM

View PostCardiacArrest, on 06 August 2012 - 04:47 PM, said:

Thanks! (again) I did get 64 bit origainally, but I"m not sure if I got 32 when I re-installed.
If you download and install java sdk 64bit, then you use 64bit java from now on. I think now also the batch file should work.Posted Image
Posted Image

#18

CardiacArrest
  • Minecraft: IAMHAZCAIK

Posted 06 August 2012 - 08:06 PM

New error!!111!1!!!! Apparently it can't access the jarfile, so I was wondering if I should just path it directly to the .jar?
Posted Image

#19

Gnampf
    Gnampf

    Coal Miner

  • Members
  • 141 posts
  • Location: Germany

Posted 07 August 2012 - 05:33 AM

No, it won't work directly with the .jar. This is the same problem as above. CMD can't find the file. May try the same like Animal 262

View PostAnimal262, on 05 August 2012 - 01:46 PM, said:

Thanks this worked. I changed the bat back to a txt, changed 'minecraft.exe' to full path name 'c:/....minecraft.exe' and it has incresed the ram in game.

Posted Image

#20

CardiacArrest
  • Minecraft: IAMHAZCAIK

Posted 07 August 2012 - 12:50 PM

Alright, I have come to the conclusion that is does not work. Minecraft seems to be running okay, and I'll be getting more RAM soon. Thanks for all the help, and I might PM you if I really need t.
Posted Image