How to allocate more ram to a direwolf20 server, hosted at home

Status
Not open for further replies.

underground5456

New Member
Jul 29, 2019
22
0
0
can someone tell me how to allocate "X" gb of ram to a dw20 server hosted at home? thank you very much. (in complete detail)
 

TheSandwichMakr

New Member
Jul 29, 2019
582
0
0
Open your startup script. There should be an option that says -Xmx1024M change the number to however many gigabytes you want to allocate multiplied by 1024. You may have to install 64-bit java to allocate more than x ram if you're using 32-bit. You should leave some ram for the system or else it may crash. I also suggest adding these option but it's not necessary.
-server -Xms1024M -Xmn512M -Xincgc -XX:UseSSE=4 -XX:+UseCMSCompactAtFullCollection -XX:+UseConcMarkSweepGC -XX:+DisableExplicitGC -XX:+CMSIncrementalMode -XX:+CMSIncrementalPacing -XX:+UseCompressedOops -XX:+AggressiveOpts -XX:+CMSClassUnloadingEnabled
If you have a multi-core processor you can also add -XX:parallelGCThreads=1 with 1 being replaced by how many cores you want to allocate to the server. (Replace the ':p' with a colon and a capital 'P')
 
  • Like
Reactions: underground5456

underground5456

New Member
Jul 29, 2019
22
0
0
Open your startup script. There should be an option that says -Xmx1024M change the number to however many gigabytes you want to allocate multiplied by 1024. You may have to install 64-bit java to allocate more than x ram if you're using 32-bit. You should leave some ram for the system or else it may crash. I also suggest adding these option but it's not necessary.
-server -Xms1024M -Xmn512M -Xincgc -XX:UseSSE=4 -XX:+UseCMSCompactAtFullCollection -XX:+UseConcMarkSweepGC -XX:+DisableExplicitGC -XX:+CMSIncrementalMode -XX:+CMSIncrementalPacing -XX:+UseCompressedOops -XX:+AggressiveOpts -XX:+CMSClassUnloadingEnabled
If you have a multi-core processor you can also add -XX:parallelGCThreads=1 with 1 being replaced by how many cores you want to allocate to the server. (Replace the ':p' with a colon and a capital 'P')
can you post or attach the correct file for five gb of ram and tell me where to put it i am having great trouble
 

Ashzification

New Member
Jul 29, 2019
7,425
1
0
http://www.minecraftwiki.net/wiki/Tutorials/Setting_up_a_server

All you need to do is create a Notepad file (as indicated in the tutorial).
Where the numbers are, put in the amount of ram you want (5120)-just replace the 2 numbers in the line of code with 5120
Replace Minecraft server (at the end) with "direwolf20.jar"
When you save the file, save it as run.bat, making sure that the drop down menu (below the naming line) is set to all files.

"C:\Program Files\Java\jre7\bin\javaw.exe" -Xms5120 -Xmx5120m -jar "direwolf20.jar"
 
Status
Not open for further replies.