Feasibility of my server concept

Discussion in 'Server & Community Management' started by PitPanda, Jun 22, 2018.

  1. Hey Folks,

    I want to start a server project. Now I want to ask you if it's possible to create a server like this and maybe where I will run into problems and possible bottlenecks. Maybe you have some tips which plugins to use (Permissions and Protection)

    I want to create a server where every player has it's own world. The world will be capped from 8x8 up to 20x20 Chunks. The player must be able to set Flags like PVP, pick items etc. Also the owner of a world has to manage memberships of his world, set regions which can be rent to other players and manage who can use interactable blocks like buttons etc., this includes to set fees on it. There should be the capability for other players to visit those worlds, even if the owner or any member of this world isn't online. In addition the owner should be able to deside, if other players may join without asking / with asking / or if no one is able to join the world.

    Problems I see
    • many disc space! I think every world (end and nether included) will take up to a minimum of 15mb disc space
    • loading and unloading process of worlds
    • lesser issue - generating the world and set the owner, I think this will be a simple copy and paste job in the background
    I have no idea how many worlds a Spigot server can manage at a time and what kind of machine I need to do this job for x worlds at a time and x players on a server (200 slots would be a good number in the first place)? I thought of having multiple servers and let them auto loadbalancing worlds to different server instances but maybe I don't need tihs? Well when I have multiple server instances I need a way to share server configs / world configs unless all configs are in a database to have them at one place I have no solution for this yet.

    For the world protection part I would use WorldGuard, I didn't find another good plugin and I'm able to hook into WG with my create/load/other plugins. Also there are many Plugins which can work with WG like signs etc. For the permission part I would use PEX. Do you have other suggestions for plugins?

    Just in advance, I know that this is possible on small numbers, but how about scalability in regard of lags / low tps?

    Greetings
    Pit
     
  2. just set view distance to something low and keepspawninmemory to false, you should be able to run smoothly
     
  3. The idea is definitely possible and not really unrealistic. I would guess however that you may need some custom plugins developed in order to get this to run nice and properly. Having to load and unload worlds all the time may indeed cause somewhat of a bump here and there, though it depends on how frequent it is. Naturally, smaller worlds take less effort to load, so I wouldn't really worry about that. Then again, if you can develop plugins yourself, creating some kind of stress test shouldn't be an issue (try loading and unloading a world every 10 seconds for example and see what it does to the TPS) so you can just test it out.

    As per disk space, I think it will be fine. The 15mb you mentioned, is that the 8x8 - 20x20 world including end and nether? If so, it's safe to assume every registered player will take up 15mb. Depending on the type of server you get, storage page will differ. A large SSD dedicated server probably has between 250 and 500 GB of storage, which is (using the 15mb from earlier) equal to about 1600 (250gb) to 3300 (500gb) registered players. If you choose to not get an SSD, you may have about 1 to 2, or even 4 TB of storage which significantly helps in storage, but may or may not be a good idea in terms of performance if you constantly need to load/unload worlds.

    One other issue you will run into which you (from the looks of your post) haven't thought about is data distribution. Let's say you need multiple dedicated servers. How will you make sure all world data is available to all servers? Depending on what kind of world we're talking about, you may want to change the way worlds are saved. For example, if the terrain is pre-generated and the same for every player, you could choose to save only modifications of the world into a JSON file. For example, all players are given a 20x20 chunk world which is the same for everyone. The player breaks a block; this block break gets added to the JSON as a modification. Then, you only need to keep one world file as a template, load this world, and then apply the modifications on top of it, which would remove the block and the player wouldn't notice anything. If you have the same world for each player (or a set of templates), I would consider this as it may help in storage. It will especially help keeping disk usage low for players who aren't doing anything. Say, a player joins the server, makes a 15mb world, then leaves. Then what? 15mb wasted. With the idea above, if the player doesn't do anything, the JSON file would be empty and practically no (just a few KB) of space will be used.
     
    • Friendly Friendly x 1
  4. Thanks for your reply. I already have a dedicated server, it's just abandoned for 2 years now, I'm just paying for it but it's unused. :) The idea of a stress test came to my mind too in the last couple of days, maybe there is an easy to use plugin to make some stress tests, also with loaded chunks in the loaded worlds, I'll definitely give it a try.

    The thing with a player joins takes a world and is not coming back again, is also in my mind, I'll write a simple plugin or shell script which checks if a world is abandoned and will softdelete this world and dump the world after a period of time to save disc space. I have a 500 GB SSD in the machine, but always the option to get more HDDs which is relatively cheap (15 € p.m. 500 GB SSD).

    The issue with sharing data between multiple dedicated servers can be a pain yes you are right, but I think it's not necessary in the first place. I think when I need more dedicated servers I can scale in the datacenter and share data between those servers I think it would be fast enough, little delays while loading a world is not a problem maybe. =)

    The idea of changing the way how to save the world sounds very interesting to me. As I understand it correct, you mean I have N world pattern which a player can choose from and every change made to the dedicated world, will be saved into a JSON. When loading a world, the JSON will be applied to a copy of that world first and the world will be loaded afterwards. Phew sounds tricky. :) Are there any references or examples or have anyone ever done that? When I think of a players world which got heavily modified it seems not the best solution, but on small worlds it's a good idea. hmm