HomeНаука и техникаRelated VideosMore From: Todd Boniface

How To Allocate More RAM To Minecraft Server for Mac OS X

115 ratings | 29987 views
Code to paste in. java -Xmx1024M -Xms1024M -jar minecraft.jar There are other ways of allocating more ram to a minecraft server, but this is one of the simplest.
Html code for embedding videos on your blog
Text Comments (124)
Mason Duncan (4 months ago)
thanks dude this really helped
SunnyPopfeline (10 months ago)
Question. I have type this in my "terminal" to give 1024m and some time later, it says "disconnected" when i log in. I manage to get in only once. The server seen, little lagging but also in a feeling of "If I do anything big it will crash" after awhile of looking around for the world to load (not moving from my current spot) it crash's and logs me out. is it because it doesn't have enough ram or do I need to type this in every time I "open" the server?
Zahtec (11 months ago)
It just WRECKS my java and then says an error!
Steven909 (1 year ago)
when I hit enter i get the following error code: Exception in thread "main" java.lang.UnsupportedClassVersionError: net/minecraft/server/MinecraftServer : Unsupported major.minor version 52.0 at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClassCond(ClassLoader.java:637) at java.lang.ClassLoader.defineClass(ClassLoader.java:621) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141) at java.net.URLClassLoader.defineClass(URLClassLoader.java:283) at java.net.URLClassLoader.access$000(URLClassLoader.java:58) at java.net.URLClassLoader$1.run(URLClassLoader.java:197) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:190) at java.lang.ClassLoader.loadClass(ClassLoader.java:306) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at java.lang.ClassLoader.loadClass(ClassLoader.java:247) Note: This happens whenever I open start.command too... any info would be great.
MilesGaming (2 years ago)
java -Xmx3G -Xms3G -jar minecraft.jar
Bromthymol Blue (2 years ago)
? launches, but then crashes saying that the state engine was in incorrect state
Holger Tammela (2 years ago)
HERE IS THE RIGHT CODE YOU NEED! java -Xmx1024M -Xms1024M -jar minecraft_server.jar
TheCriticOfSwag (2 years ago)
It said. The state engine was in incorrect state POSTINITIALIZATION and forced into state SERVER STOPPED. Errors may have been discarded.
Boondocky (3 years ago)
Finally! A video that has actually got me somewhere. Lol Thank you Todd!
Zelda (3 years ago)
it sais unable to acsess jarfile
Voschdasirup (3 years ago)
+GreenHeroGaming To annyone getting the "unable too access file" statement: Todd made a mistake in the Video description (one can actually see what he writes in the video..) After doing doing the cd (forge server folder) command and hitting enter you need to type the following: "java -Xmx1024M -Xms1024M -jar minecraft_server.jar" Todd mistakenly wrote the RAM allocation command for Minecraft itself instead of the Minecraft Server. In my case (using forge server) I need to write "minecraft_server.1.8.8.jar" into the java command line. So the general rule of application is: Write the java command and then the name of the .jar file of your server, so if you rename it to "mcswaggalot.jar" for example you would need to add that instead of "minecraft_server.jar" at the end of the java command line. Hope you get the point. Have a good one!
Phaxtolgia (3 years ago)
it says its unable to access the file. I double checked all the info and it should work.
Voschdasirup (3 years ago)
+Superterry Btw, read the comments below, the problem had been solved by other users already;)
Voschdasirup (3 years ago)
+Superterry To annyone getting the "unable too access file" statement: Todd made a mistake in the Video description (one can actually see what he writes in the video..) After doing doing the cd (forge server folder) command and hitting enter you need to type the following: "java -Xmx1024M -Xms1024M -jar minecraft_server.jar" Todd mistakenly wrote the RAM allocation command for Minecraft itself instead of the Minecraft Server. In my case (using forge server) I need to write "minecraft_server.1.8.8.jar" into the java command line. So the general rule of application is: Write the java command and then the name of the .jar file of your server, so if you rename it to "mcswaggalot.jar" for example you would need to add that instead of "minecraft_server.jar" at the end of the java command line. Hope you get the point. Have a good one!
CrazySmile (3 years ago)
Thank You
Brody Robbins (3 years ago)
Hey Todd I cant make a minecraft server its something with my mac can you make a server and make me have Owner Permissions Plz
SexyBlackDooochheee (3 years ago)
+Noble Draft you will need to start the server and then type in on the terminal op player name, then enter, that is it!!
Caam (3 years ago)
Amazing video it helped me a lot I changed 1024 to 10240 so it would run even faster and now it's perfect.
YumSoup :/ (2 years ago)
+Snaddle not good idea
MoosenGaming (3 years ago)
i get "-bash: syntax error near unexpected token '( '    "    help!
moto324 (3 years ago)
its broken :(((((((((((((((
liam benecke (3 years ago)
thx that help a lot
Star Derp (3 years ago)
#!/bin/bash cd "$(dirname "$0")" exec java -Xmx3G -Xms3G -XX:PermSize=2G -XX:MaxPermSize=2G -jar craftbukkit.jar nogui (apart of line 3) this is a simple program that when named to a start.command (.command file) using text edit, all you do is put this in with your minecraft files and launcher it (of course make sure the name is the same)
Joseph_Geraci (4 years ago)
how do i delete this stuff from terminal i can't get rid of it now
Ryan Norman (4 years ago)
you need to give a more clearer way of explaining how to do this.
Oneforestboi (2 years ago)
+Todd Boniface does this work for 1.8.9???
Todd Boniface (3 years ago)
Thanks JediMasterBenScratic :P 
Jackson of the Mardu (3 years ago)
+Ryan Norman I understood it perfectly fine.
Ryan Norman (4 years ago)
:)
Todd Boniface (4 years ago)
Sure thing Ryan. It is about time I remade this video.
ToxicChim23 .1234 (4 years ago)
please help me! when ever i do this and i do it correctly i start to go into my server and play but it keeps saying can not keep up what do i do please help me!!:(
Schmobby Burda (4 years ago)
mine is named minecraft.jar :S
GrizzlyBearGamer (4 years ago)
mine says Permission denied
Jackson of the Mardu (3 years ago)
+GrizzlyBearGamer Your computer has parental controls, and your parents have not given your account permission to do that.
HuffEffects (4 years ago)
its cool how that works. do you know how to undo it?
HuffEffects (3 years ago)
+JediMasterBenScratch lol it happens :)
Jackson of the Mardu (3 years ago)
+HuffEffects Oh, didn't read the date LOL.
HuffEffects (3 years ago)
+JediMasterBenScratch Thanks! but i think you're a little late :P
Jackson of the Mardu (3 years ago)
+HuffEffects Do /stop in the server console.
oliver lebert (4 years ago)
you just close the window
Mr26391br (4 years ago)
says unable to access jarfile minecraft.jar
Jackson of the Mardu (3 years ago)
+Mr26391br Change minecraft.jar to the name of your server program.
Javier Correa (4 years ago)
Remmember after cd there is a space
GrizzlyBearGamer (4 years ago)
mine too
Michael Pemberton (4 years ago)
Thank you so much man! You're the best! If you can't access the file, simply rename the start server server command to minecraft.jar
Evan Lyons (4 years ago)
thank you so much!!! :)
Carlos Vives (4 years ago)
So i have to do that every time i open up my server? 
Jackson of the Mardu (3 years ago)
+Carlos Vives You can leave it on, as long as your computer is not shut down it will be on.
Sneaking Dawg (4 years ago)
I think so.. :( I would love to be able just to click on something to open it, like a normal vanilla server...
Advaith Narayan (4 years ago)
It worked! YAY thanks. And for the people who are unable to access jar file, mine was named minecraft_server.1.7.10.jar. So check your server.jar file name and then it should work.
Evan Lyons (4 years ago)
this helped a bunch thx :)
Fulton Collins (4 years ago)
it says unable to access jarfile mine craft.jar please help
Jackson of the Mardu (3 years ago)
+Mr.Bates Change minecraft.jar to the name of your server program.
GrizzlyBearGamer (4 years ago)
mine too
Mala (4 years ago)
Hey Todd, thank you so much for this. Completely sorted my issues.
Magmafrost13 (4 years ago)
servers default to 1Gb don't they?
Jackson of the Mardu (3 years ago)
+Magmafrost13 Mine defaults to 64 megabytes.
Jackson of the Mardu (3 years ago)
+Magmafrost13 64 Megabytes
Todd Boniface (4 years ago)
Hm. My server never had 1gb of ram available. Anyway.
Magmafrost13 (4 years ago)
+Todd Boniface Hmm, I skipped everything between 1.0 and now, and I seem to remember my old servers having 1Gb. Maybe it changed somewhere in between, or maybe I'm just wrong.
Todd Boniface (4 years ago)
I don't think they used to.
don clik fagt (4 years ago)
For the people that it doesn't work for; java -Xmx1024M -Xms1024M -jar minecraft_server.jar This is the code you have to paste. Todd has copy pasted the more ram to your own personal minecraft launcher and game, not the server itself. I hope this helped!
Chi sarades (4 years ago)
thanks
LikeJoeBossMan (4 years ago)
Thank You!
Donald Mathews (4 years ago)
hey man, in the code that you put in the description you had minecraft.jar instead of minecraft_server.jar. use this instead of that in the terminal yall.
linkshroom (4 years ago)
it says it cant access
George Cook (4 years ago)
cheers mate 
Dan (4 years ago)
this video is very useful thank, but below i've seen a couple of people having some issues ... after you've sourced the folder (drag and drop after typing "cd") when you come to copy and paste the text in the description make sure you enter the full/exact name of the file you wish to allocate the ram to ... e.g. i had to enter minecraft_server.1.7.5.jar for mine to work ... it also started the java file (the server) to which i left it a couple of mins and typed "/stop" to close it ... Hope this helps to anyone having issues :)
TheCoolCat 11 (3 years ago)
Thx for the help
EffexGaming (4 years ago)
it work for me but it says you don't have acces to that command while im op
Lee Swain (4 years ago)
it says that   unable to access minecraft_server.jar
Lee Swain (4 years ago)
yes
Todd Boniface (4 years ago)
Check to see if your minecraft file name is the same as mine. 
Arcady Ourumov (4 years ago)
these codes are shit the don't work at all
Young Escapé (4 years ago)
thanks helped a lot!
Todd Boniface (4 years ago)
Glad I could help!
ProjectMoff (4 years ago)
I've been looking for a fix for hours, none of these codes work :(
eperderp (4 years ago)
+ProjectMoff This worked thank you.  I only had to change the "1.7.4" to "1.6.4"
ProjectMoff (4 years ago)
If you mess up it just wont do what you want it to do, nothing will happen if the code is wrong because it wont be recognized, I was weary at first but I have had no problems at all.
oliver lebert (4 years ago)
+ProjectMoff is it a way to undo the changes if you mess up?
ProjectMoff (4 years ago)
Update: Looking at the official minecraft tutorial i found this code and it worked for me..... java -Xmx2G -Xms2G -jar minecraft_server.1.7.4.jar -o true
Alex K (4 years ago)
Fuckjing unable to access jar file -1
Daud A. (1 year ago)
Thank you.
Jackson of the Mardu (3 years ago)
+Alex Kaliswaagg Change minecraft.jar to the name of your server program.
Gunnar Starleaf (4 years ago)
ME TOO!
Yo_wotup (4 years ago)
SOLVED IT, type this in  >    inteadcjava -Xmx1024M -Xms1024M -jar.minecraft_server.1.7.4.jar
Todd Boniface (4 years ago)
Thanks
billion256 (4 years ago)
+Alex Kaliswaagg It does
Alex K (4 years ago)
that doesn't work -.-
Yo_wotup (4 years ago)
>> got it wrong << java -Xmx1024M -Xms1024M -jar.minecraft_server.1.7.4.jar
Andrew R. (4 years ago)
Unable to access jarfile minecraft.jar
Eduardo Diaz (4 years ago)
unable to access jar file
Terrible Matt (1 year ago)
You need to replace the "minecraft.jar" by the name of your server followed by the extension (.jar)...
Todd Boniface (3 years ago)
Hmm. I'll look into it scarecrow.
SCARECROW (3 years ago)
+Todd Boniface hey i am running this on 1.1.8.7 will this not work with the 1.8 update i know its slightly different becaue i did type it exactly as my file name and it stil said unable to access the jar file
Todd Boniface (4 years ago)
All good we all make mistakes :)
Christian Rhodes (4 years ago)
+Todd Boniface  Hey, finally I have realized that my minecraft.jar file was named minecraft_server.1.7.9.jar. So i renamed it to minecraft.jar and it worked! I feel like an idiot...
TigerPlaysGames (5 years ago)
It did not work I did everything, but it sats Unable to access jarfile minecraft.jar
Attatsu (5 years ago)
When i do this it says on the server window that i have less % memory free, any idea why?
Eric Zaksauskas (5 years ago)
ya this way is the most simple and MOST unnsuccesful. Nice try, bud
Eric Zaksauskas (5 years ago)
java -Xmx1024M -Xms1024M -jar minecraft_server.jar
Eric Zaksauskas (5 years ago)
It did not work I did everything, but it sats Unable to access jarfile minecraft.jar
FiZ Oreo - (5 years ago)
Mine says unable to access jar file. Do i have to install something to allow this to work?
AriFranco (5 years ago)
Sometimes it means that the server is already running
AriFranco (5 years ago)
When you type in the code, try typing: java -Xmx1024M -Xms1024M -jar minecraft _server.jar I think it said that because the server file is not named "minecraft.jar", its name minecraft_server.jar I hope that works it worked for me.
I am An IamsDog (5 years ago)
LMAO what a shitty reason to dislike
Tom K (5 years ago)
It's the computer of choice for most of the music industry, but yeah, school computer
Tycho de Rijke (5 years ago)
It says: unable to access jarfile minecraft.jar.. I think it could be because I am using forge and other mods.. Anyone else came accross this problem?
Mining Pvp (5 years ago)
ukkomies100, to copy it right, use ava -Xmx1024M -Xms1024M -jar minecraft_SERVER.jar... u need the _server, but not in caps, he typed it wrong in the desc
Todd Boniface (5 years ago)
sounds like a router issue.. check on Google for how to set up a minecraft server.. you have to unblock certain ports on your router.
Matthew Robertson (5 years ago)
it always says FAILED TO BIND PORT
Minecraft Vector (5 years ago)
it just says -bash xmx1024m commoand not found
XxDragonBornxX (5 years ago)
How the fuck you use it with SHELL?
Brent Sparks (5 years ago)
when i do it, it just opens up minecraft_server.jar but doesnt add ram...
DclutchS (5 years ago)
i did this and it is still saying it is unable to access jar file minecraft.jar, any other suggestions?
Hey, you must be using a server file with 1.6.1 or similar at the end of it. To fix this, simply change the file's name in 'get info' to .jar, deleting the 1.6.1, this worked for me.
ukkomies100 (5 years ago)
my terminal says unable to acces jarfile minecraft.jar

Would you like to comment?

Join YouTube for a free account, or sign in if you are already a member.