Assigning more RAM to a server GUIDE!

Discussion in 'Bukkit Help' started by InhumanSkills, Jan 21, 2011.

  1. Offline

    harrisonduell

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Does anyone know how i can get more ram?
  2. Offline

    Claryn

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    I'm running McMyAdmin with Bukkit.
    I cannot assign more then 1524
    I got 64x bit
    I got 8 GB ram
  3. Offline

    sheape

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    well my computer is a:

    Asus
    i7 prosser
    8 GB of ram
    nvida GT 530

    so i want to add more ram so i go in and put:
    @echo off
    "C:\Program Files\Java\jre6\bin\java.exe" -Xms4096M -Xmx4096M -jar craftbukkit-0.0.1-SNAPSHOT.jar
    pause

    And get an error:
    "Error occurred during initialization of VM
    Could not reserve enough space for object heap
    Could not create the Java virtual machine."

    Now why is that? help please thanks
  4. Offline

    GenBOOM

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Well I did those things and it didn't work.
    Turns out the world file was corrupted.
    Good thing it was a new world at least.
  5. Offline

    Steadyedy1

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    i don't understand which one is the bat file...?
  6. Offline

    Banana937

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    That means nothing. It's a stupid error. Google search BlockCantKeepUpSpam (it's Inactive, yet works with the most recent version of Craftbukkit).
  7. Offline

    harrybridgen

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    i have internet exp bit 64, and java bit 64, 453 GB of memory on my computer,
    all good right? so i put @echo off
    "C:\Program Files\Java\jre6\bin\java.exe" -Xms1536M -Xmx1536M -jar craftbukkit-0.0.1-SNAPSHOT.jar
    pause
    just to test it, and it says:
    error loading: c:\program files\java\jre6\bin\msvcr71.dll
    error occurred curing intialization of VM
    java/lang/NoClassDefFoundError: java/lang/object
    press any key to continue....
    Any help?
  8. Offline

    InhumanSkills

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
  9. Offline

    InhumanSkills

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Sorry I have been pre occupied with school lately but i will be answering questions about how to launch your servers from now on. Once a day i will get on and check for questions. If i miss your question feel free to message me.
  10. Offline

    KaizenNeko

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    REMINDER

    Using 32-bit Windows or 32-bit Java (on 64-bit Windows) you CANNOT use more than 1GB of RAM allocated to Minecraft.

    This post has been edited 4 times. It was last edited by KaizenNeko Sep 21, 2011.
  11. Offline

    InhumanSkills

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    You buy it, make sure you computer has enough room for more ram, and that the ram you buy is compatible with the ram you already own and the socket it is placed in.
  12. Offline

    InhumanSkills

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    If you still need help please be more specific about your problem.
    Why are you not able to assign more ram?
    Best guess i have is you do not have 64 bit java.
    Open up Internet Explorer x64 and go to Javas' website. From there download 64 bit and try again.
  13. Offline

    InhumanSkills

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    If you still need help. The problem here is that you probably don't have 64 bit java installed.
    Download it from Javas website using 64 bit internet explorer.

    If you still have the problem press Ctrl+shift+esc go to performance and look at the memory usage.
    That should let you know how much available ram you have left in your system.
  14. Offline

    InhumanSkills

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    If you still need help.

    The .bat file is a file you create yourself.
    First open up a .txt document, Notepad works fine.
    Then copy paste the code that i have supplied.
    When you go to save it it will tell you the file ending is .txt simply change that to .bat and then hit save.
    It will then turn it into a .bat file and the next time you double click the file it should open your server.
  15. Offline

    The_Weaver

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Nice! My server is running quite faster now!
  16. Offline

    InhumanSkills

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Great! I'm glad I could help!
  17. Offline

    TheBeautyOfMinecraft

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Can I have some help for this? It dosnt show that to change the ram. Here is what it says:
    @ECHO OFF
    SET BINDIR=%~dp0
    CD /D "%BINDIR%"
    "%ProgramFiles%\Java\jre6\bin\java.exe" -Xincgc -Xmx2G -jar craftbukkit-0.0.1-SNAPSHOT.jar
    PAUSE
  18. Offline

    Perling

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    What is now better?

    This :
    java -Xms6144M -Xmx6144M -jar craftbukkit-0.0.1-SNAPSHOT.jar

    This :
    java -Xincgc -Xmx6144M -jar craftbukkit-0.0.1-snapshot.jar

    hmm ?

    This post has been edited 1 time. It was last edited by Perling Sep 27, 2011.
  19. Offline

    InhumanSkills

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    -Xincgc is not bad to use, it sets up incremental garbage collection but decreases overall gc by roughly 10%. You can use it if you want but for me it makes no difference.
  20. Offline

    InhumanSkills

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    I'm not quite sure what you are asking but ill try to do my best. There are a lot of things you can write into the bat file to get java to do certain things. I'm not sure why you are asking it to change the directory but if you just did

    Code:
    @ECHO OFF
    
    "%ProgramFiles%\Java\jre6\bin\java.exe" -Xincgc -Xmx2G -jar craftbukkit-0.0.1-SNAPSHOT.jar
    
    PAUSE
    it should work fine.
  21. Offline

    Perling

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    ok thank you :)
  22. Offline

    Mr Olive

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    I just updated my java to 64bit and now I can't even run the freaking server. It says "Can't find path" or whatever it says in english (I'm swedish so..)
    I've tried to understand the posts I've seen here but it doesn't make any sense to me at all. All this java mumble jumble is like trying to have a conversation with a 3 year old for me.
    I have 8GB ram and I want my server to run as smooth as possible


    All help greatly appreciated!

    Code:
    @ECHO OFF
    IF /I "%PROCESSOR_ARCHITECTURE:~-2%"=="64" "%ProgramFiles%\Java\jre6\bin\java.exe" -Xincgc -Xmx4096M -jar "%~dp0craftbukkit-0.0.1-snapshot.jar"
    IF /I "%PROCESSOR_ARCHITECTURE:~-2%"=="86"  java -Xincgc -Xmx1024M -jar "%~dp0craftbukkit-0.0.1-snapshot.jar"
    PAUSE
    

    This post has been edited 2 times. It was last edited by Mr Olive Sep 28, 2011.
  23. Offline

    Simanova

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Your
    Is inappropriate for linux users without desktop environment. You should consider to provide a gui-less guide :)

    This post has been edited 2 times. It was last edited by Simanova Sep 28, 2011.
  24. Offline

    Baummann

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Add "nogui" to your sh file
  25. Offline

    TheBeautyOfMinecraft

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    I would like to update the ram with that but i dont know how to.
  26. Offline

    InhumanSkills

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    I'm not completely sure what you mean by update the ram? If you would like to increase the amount of ram your minecraft server uses paste that into a notepad file and save the file as a .bat. You will then be able to launch the .bat file which in turn launches your server.
    Make sure you have the right amount of ram available and that your path to java is correct.
  27. Offline

    InhumanSkills

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    I wish I could go more in depth with the linux guide but I don't really use Linux much. I pretty much learned all that in an hour or so. If i have some more time after my tests i might go have another look at it.
    I posted a link to a purely Linux guide if you want to use that.
    If you need further help refer to this forum
    http://forums.bukkit.org/threads/ho...kkit-craftbukkit-server-running-java-x64.598/
  28. Offline

    TheBeautyOfMinecraft

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    I already have a .bat file starting my server. The code in it is @ECHO OFF
    SET BINDIR=%~dp0
    CD /D "%BINDIR%"
    "%ProgramFiles%\Java\jre6\bin\java.exe" -Xincgc -Xmx2G -jar craftbukkit-0.0.1-SNAPSHOT.jar
    PAUSE
    So I dot know how to upgrade the ram because it isnt the same as the code you put in the example.
  29. Offline

    InhumanSkills

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Try that.

    Obviously the path to your java file and the actual name of your craftbukkit might be different.
    I don't know why you would have an if statement to check the CPU type in your .txt?
    It might be pretty cool and all but if you know you have a 64 bit operating system why ask?

    Lycka till!

    This post has been edited 2 times. It was last edited by InhumanSkills Sep 29, 2011.
  30. Offline

    InhumanSkills

    dev.bukkit.org profile:
    CFUSERNAME
    My Plugins (CFCOUNT)
    Ohh ok well what you have there is more general for different computers. I make mine specific to my computer.
    The file essentially does the same thing.

    Try:
    @Echo OFF
    "C:\Program Files\Java\jre6\bin\java.exe" -Xincgc -Xmx2G -jar craftbukkit-0.0.1-SNAPSHOT.jar
    PAUSE

    Even this should work

    "%ProgramFiles%\Java\jre6\bin\java.exe" -Xincgc -Xmx2G -jar craftbukkit-0.0.1-SNAPSHOT.jar

    Just raise the numbers in red to whatever you would like the maximum ram set at. So here it's set at 2Gb

    I hope I answered your question.

    This post has been edited 1 time. It was last edited by InhumanSkills Sep 29, 2011.

Share This Page