Alright, so I did some research, and a couple of things come to mind.
First of all, everything related to the java parameters is bullshit primarily. Most of what people say about optimization on that area is a lie or not nescessarily boosting the performance. Nevertheless, some optimizations are important to the way Java uses memory.
When launching the server, do it through the following command:
- Code: Select all
java -server [b]-Xmx4048M -Xms4048M -XX:+AggressiveOpts -XX:+DisableExplicitGC -XX:+UseG1GC[/b] -jar minecraft_server.jar
The stuff in bold will allow Java to actually
use 4096 megabytes (4 gigabytes) of RAM, compared to the 512 megabyte default. Furthermore, it makes the GC (garbage collector) more aggressive. One thing is how much a server consumes, but that's not all that matters. If the memory is fragmented (which often happens when many people are on and more memory is consumed), it also decreases performance.
I also couldn't help but noticing that the view distance of the server is at around 10. This means that X amount of blocks get sent to the client, regardless of their client view distance. The default value is 10, the maximum value is 15 (set in the server.properties file) and the normal value is 8. A value of 8 or 6 should be acceptable among players, and many servers use this.
The last suggestion I have is to make a RAM-disk. I'll now quote a resource I found online:
Lastly, you will probably want to cut down on I/O waits generated from reading/writing chunks a lot. You cannot reduce the number of waits, but you can cut down on the duration of the waits by stuffing the map into a ramdisk using a tmpfs (ramdisk and tmpfs make for good keywords for google if youve never done this before). A regular map on a SMP server is likely to be around 2GB+ in size, but I doubt a UHC map would even come close to reach 512M, but you should have numbers for this from previous UHCs).
For minecraft you would create a ramdisk of the required size and mount it to ~/server-dir/World-dir/:
mount -t tmpfs -o size=1G,nr_inodes=10k,mode=0775,noatime,nodiratime tmpfs /path/to/World-dir/
echo “1″ > /proc/sys/vm/swappiness
the last part helps avoiding swapping
Now RAM is volatile, so you will probably want to set up a cronjob that periodically (incrementally!) rsyncs the map to disk - because doing backups is always a good idea. Every 30 minutes should be fine.
This will gain you huge performance boost.
I hope some of this helps.