out of memory

If you're having problems with your installation of Better Than Wolves, or if you've woken up in the future and are beginning to doubt the nature of reality, here's the place to post about it.
Post Reply
User avatar
Rugaard
Posts: 201
Joined: Wed Jul 06, 2011 7:38 pm

out of memory

Post by Rugaard »

i keep on getting out of memory, i doubt its a bug but is there anyway to increase the memory allocation for java?
User avatar
Battosay
Posts: 2043
Joined: Mon Jul 04, 2011 7:37 pm

Re: out of memory

Post by Battosay »

I don't know much about that matters, but it's only happening to me when I'm playing on far/fancy graphics. Try to lower your settings.
User avatar
gftweek
Posts: 674
Joined: Thu Jul 07, 2011 5:33 pm

Re: out of memory

Post by gftweek »

First google link seems worthwhile for this, thanks google. ;)
User avatar
Rugaard
Posts: 201
Joined: Wed Jul 06, 2011 7:38 pm

Re: out of memory

Post by Rugaard »

gftweek wrote:First google link seems worthwhile for this, thanks google. ;)
lol i have no idea what he said
User avatar
finite8
Posts: 587
Joined: Mon Jul 04, 2011 9:31 pm
Location: Melbourne, Australia

Re: out of memory

Post by finite8 »

First up, what are your system specs?

Have a read of this article i posted ages ago at get satisfaction:

http://getsatisfaction.com/mojang/topic ... t_problems

Mainly under the performance section. Might help you out.

If not, then make sure you have the latest Java Runtime installation.
Flowerchild (IRC) wrote:I'm not trying to stop you BTW ..., I'm saying that I think you're a piece of shit...not the same thing
User avatar
gftweek
Posts: 674
Joined: Thu Jul 07, 2011 5:33 pm

Re: out of memory

Post by gftweek »

You just need this bit:
Now minecraft uses a default memory of 495Mbs, but you can allocate more. Here's how you do it (assuming you have more).

#1First create a .txt file in the same folder as your minecraft.exe.
#2Then open that file.
#3Type these two lines of text:

@ECHO OFF
"Your java path here/javaw.exe" java -Xmx1024M -Xms1024M -jar "Your minecraft path here/minecraft.exe"

#4Then save that file as a .bat file (aka Batch file). The way you do this is in the menu, hit Save-As, click "All File Types" and then change the name from XXX.txt to XXX.bat. The icon should change if you did it correctly and you should be able to run it. Hit F3 to make sure the allocated memory changed while running minecraft.

So create a text file on your desktop.
Type this into it: "Your java path here/javaw.exe" java -Xmx1024M -Xms1024M -jar "Your minecraft path here/minecraft.exe"
Save text file as minecraft.bat.
Run minecraft by opening the minecraft.bat file instead.

Also if you are running 64 bit windows, Java 7 64 bit is a good idea to use, better performance than Java 6.
User avatar
Battosay
Posts: 2043
Joined: Mon Jul 04, 2011 7:37 pm

Re: out of memory

Post by Battosay »

Oh, it looked interesting, sadly it's not doing anything for me. I did exactly what was said, but the allocated memory doesn't change :/
Is this still working ?
User avatar
gftweek
Posts: 674
Joined: Thu Jul 07, 2011 5:33 pm

Re: out of memory

Post by gftweek »

Works for me, I forget though, it might be that 1024MB was already the maximum allocated memory, that line just seems to bump up the minimum.

Myself since I use a 128px texture pack (more resource heavy), I allocate 2GB of memory:
"C:\Program Files\Java\jre7\bin\javaw.exe" -Xincgc -Xmx2048m -jar "C:\Users\Glenn\AppData\Roaming\aMineCraft\Minecraft.exe"
I have however read that to increase performance (less lag) you can go the other way and limit the amount of memory allocated, this is from the optifine MCForum page, where it states that if you are using the default (or another 16px) texture pack, 256MB of memory is enough, more and you get more disk caching involved so it slows down, read the section under tips and tricks, and the cmd file has to be saved to your .minecraft folder:
set APPDATA=C:\Minecraft
start /high javaw -Xmx256M -Djava.library.path=bin/natives -cp bin/minecraft.jar;bin/jinput.jar;bin/lwjgl.jar;bin/lwjgl_util.jar net.minecraft.client.Minecraft <username> <password>
Post Reply