How many RAM?

Discussion in 'Performance Tweaking' started by fer112233, Jun 28, 2016.

  1. Hi, i need to know how many RAM to a server whithout plugins, only a minilobby for about 120 players
     
  2. 4gb? Besides, its not all about ram...
    Consider researching...
     
    • Funny Funny x 1
  3. Normal minecraft servers recommend 1gb per 20 players.
    A lobby doesn't need to generate land and doesn't load a lot of chunks. And not a lot of entities. This does mean that you dont need a lot of ram. For 120 I think 3gb could be enough. Maybe less.
    But it's not all about the memory. You need to tweak the server quite a bit to make it fast.
     
    • Useful Useful x 1
  4. This is the most sensible post I've seen on these forum about RAM. I'd say 2.5GB, a good processor should be a more important in choosing.
     
    • Agree Agree x 1
    • Winner Winner x 1
  5. Why would you even put 120 players in 1 minilobby?

    If you let 120 players join/leave at the same time I think you would need better specs, unless you are Hypixel ;) (Skywars Mega)
     
    • Friendly Friendly x 1
  6. I think you shouldnt only think about the RAM but also about the CPU... Its also important for minecraft servers...
     
    • Agree Agree x 1
    • Funny Funny x 1
  7. Buzzzy

    Supporter

    I would say 4 gb, and I would advise going with a dedicated machine for your servers so you so you are not sharing resources with other servers.
     
  8. Im not Sure I have 6 gigs all in all but I run 12 mods around 40 plugins and got up to 80 players at a time with small amount of lag But 3 or 4 Gigabytes should be good enough but i dont know of any server without plugins in a Hub or Lobby, even so that should be plentyful

    I Know Nothing of CPU
     
  9. Three things:

    Memory
    Cores (and vendor)
    Network
    Optionally persistent storage options but that's not usually a huge factor

    Memory: More is always better. Always. The underlying system needs RAM and the services on the system need RAM. Forgetting about Minecraft, I wouldn't run a box with less than 32Gb RAM. Give the system head room. Avoid swapping. etc..
    The players/per/Gb rule is not scientific. It comes down to what you're running on the Minecraft server. Plugins/mods with requirements for processing (think TE, built in services like dynmap, etc..) all chew into your holy TPS rate of 20/sec goal.
    I'd give at least 4Gb to the JVM and the rest depending on how many players and _what_ kind of mods/plugins you are running. You need to make measurements and gain data about what your particular system is doing.

    Cores: More is always better. Always. But, it depends on the vendor. Intel has by far been outscoring AMD with respect to per core performance. I would avoid AMD silicon for running MC servers. They aren't historically going to give you the best bang for the buck. CPU benchmark sites will let you price and choose the right core. Going back to the previous point: your Minecraft server is hardly the only thing running on the system. Leave room for the system (2-3 cores), leave room for persistent storage via databases (mysql, etc), and then a few cores for better performance of the Minecraft server. A 2-core silicon for running a production public server is asking for trouble.

    Network: Your server may be slick and hot, but the network will kill you on performance. Is it commercially hosted? What's the backbone bandwidth? Is it centrally located in geography? Or is it located where you want the main player base to come from? What network is your ISP on? Or is this a server in your garage? The ISP (commercial, residental, etc..) will be the primary factor. There are several good companies involved in renting systems with generally good network positioning. I won't mention them by name (I could leave one out offending someone ;-)

    Storage: Yes, SSD is faster than HDD. Orders magnitude faster. But in the scheme of things it really is not _that_ big of a deal unless you have higher than normal server performance requirements. When faced with the question, put the _game on SSD_ but leave the operating system on HDD. You can always mount certain areas of the game on HDD partitions and leave the world on an SSD partition.

    The bottom line is that you need to accumulate data and make a factor/response analysis of the changes you make and the outcome performance of the system.

    Accumulate data on:
    load average (top or similar)
    amount of memory available (vmstat)
    aggregated CPU utilization of each process.
    how many players you have
    what plugins/mods are installed
    -- and what are those plugins/mods doing? how many of them rely on filesystem vs. database for persistent storage
    -- how many of them create threads ?
    -- how many of them are doing backdoor services (like dynmap for instance)

    Collect data for some time with a baseline of hardware. Then evaluate the results. Do you need more RAM, a better Processor, a better Network?

    Good luck.
     
    • Informative Informative x 1
  10. FHR

    FHR

    For lobby set view-distance to like 4. Then you should be good with 3Gigs or so. But as mentioned, you need a good CPU.
     
  11. I actually disagree. You can bump it up to 16. People in the lobby always move around the lobby so all the chunks are loaded anyway. If not they keep loading them and unloading. So you would be better off setting it to a high value because then the chunks don't need to be loaded and unloaded a lot when people move around. And then people can see more of the lobby.
     
  12. IIRC, view distance is going to affect two things the most:

    Network usage
    Throughput of the CPU

    Here's why: The more chunks that need to be visible means more data to send to the client. That's going to impact the usage of the network (both at the server and downstrream to the client). More data is more packets. More packets, more network traffic. The end user may be on a poverty system. So by increasing the view distance you're unwittingly making their system work a bit harder too. Think worst case scenario -- if their system is very basic, having that extra work (more data and more packets to resolve) makes the game look sluggish from their end.

    Second, the more chunks that have to be visible is going to trigger the server to work a bit more to prepare those packets that contain information about the (now) visible chunks. And, if any of those chunks that would otherwise not be visible (or part of the chain) contain entities that trigger more processing (TE), then you can see the cascade effect on your server now.

    I would say, that the tweek you can make on visible chunks is a last resort with respect to affecting server performance. There are already more basic and fundamental things you can do (Memory, CPU selection, etc..) that would preclude view-distance as the magic bullet to resolve a performance issue.

    Good luck.
     
    • Agree Agree x 1
    • Informative Informative x 1
  13. Please, god no.
    More =/= Better in this case, single threaded performance is what matters more for MC.
     
  14. Totally agree. Thats a valid point absolutely. That's where Intel seems to excel in their design of silicon.

    However:

    The point was, that you devote at least one core to MC when there is a condition that MC is purely single threaded. But the fact is, you cannot always be sure that your software is single threaded. A plugin can make a thread. Not ideal if the data is data that should be accessed synchronously (like world data, or files). A plugin author can really make a mess of things if they don't do it correctly.

    You are absolutely right that the MC engine is single threaded. But add-ons, plugins, etc.. cannot be guaranteed to be single threaded. In fact in the case of some plugins they may be able to do their own synchronization just fine when they employ multiple threads. [edit: meaning the plugin author may design the plugin to do out of band tasks that do not touch world data/files and do so safely in their own threads as long as they synchronize access to the data the plugin is managing]. It's not unheard of.

    The other parts of the system *cough* like the OS, MySQL, etc.. need their own cores too. So, yes, you need more cores. More cores always better. The system does more than simply run Minecraft. Just something to keep in mind if you manage a system.

    [edit: I knew that feeling of deja-vu was not a mistake. I think I posted to this point on another forum some time back, a couple years maybe:
    http://forum.feed-the-beast.com/thr...erver-owner-must-read.6010/page-6#post-653873

    There the nitty gritty details on measuring performance are discussed. YMMV]
     
    #14 sibomots, Jun 30, 2016
    Last edited: Jun 30, 2016
    • Informative Informative x 1
  15. It's not all about RAM. CPU comes to play as well.
     
    • Agree Agree x 1
  16. ^
    If you have a 128 GB server with a pentium III processor you're not gonna get a lot of performance...
    If you're looking for a decent server, you want a recent-gen i7 at the least.
     
  17. Yeah definitely.
     
  18. twelve minus six cloud, yes or no?
     
    • Optimistic Optimistic x 1
  19. JamesJ

    Supporter

    That doesn't mean you need 40 cores...
    Plugins use threads, not cores. And most plugins use a thread for a singular task, such as a database check. Not a repeating thread. So you will actually have very few constant threads that are always there.
    An i7 4790k is where it's best here.

    It has 4 cores, yet it has the best single threaded performance. Yet each core comes with 8 threads.
    4*8=32 high(est) performance threads you will get anywhere. I'd be incredibly shocked if you're using more than 32 threads at any time on a single server, I'd be surprised if you're using more than 10 tbh.

    TL;DR: More cores is not better. You want more power per thread. Just because you have a high power->core ratio, doesn't mean the CPU only has 1 thread.
     
  20. wait, each core has 8 threads?