What is BungeeCord?
BungeeCord is a software used to allow users to easily create a network of servers. You can learn more about it here:Ã‚Â https://www.spigotmc.org/wiki/bungeecord/.
To setup bungeecord, you must have a minimum of three servers with us at WitherHosting. One server is the bungeecord server itself, your second server is your "hub" server, for example, and your last server is your "smp" server, for example. You can setup the bungeecord server to allow players to easily switch between theÃ‚Â hubÃ‚Â andÃ‚Â smpÃ‚Â server.
Continuing into this article, let's call the bungeecord server as a proxy server, and let's call the hub and smp as backend servers.
Theoretically, it is possible to setup bungeecord with only 2 servers, one the bungeecord, and the other server being hub. But, the point of using bungeecord ( which is switching between servers in a network ) renders pointless.
Prerequisites to setting up the BungeeCord server -
Your non-bungee server IPs and ports.
How to setup the BungeeCord server
A bungeecord server requires very less RAM compared to other servers. A bungeecord server is not accessible in-game, because it redirects the user to the secondary and tertiary servers you have.
First, you need to go to yourÃ‚Â config.ymlÃ‚Â file in the root folder of your proxy server. We will explain line by line, what each bit means. We will not talk about a few values in the config.yml, as they are not necessary to be edited to set it up.
forge_supportÃ‚Â - Set to true if you want to allow players with forge clients to join
player_limitÃ‚Â - Global player limit for your BungeeCord instance. If set toÃ‚Â 0 or below, this will allow an unlimited amount of users to join.
online_modeÃ‚Â - Set to true toÃ‚Â notÃ‚Â allow cracked players to join, set to false to allow cracked players to join.
serversÃ‚Â - This is the most important section. In this, you will be listing all your backend servers that the proxy server should be listening to. Here is an example of a server -
lobby: motd: '&1Just another BungeeCord - Forced Host' address: localhost:25565 restricted: false
lobbyÃ‚Â would be the name of your server.
motdÃ‚Â would be your motd of the backend server you've specified.
addressÃ‚Â would be your backend server's ip address, along with the port.
restrictedÃ‚Â restricted prevents players from joining the server unless they have the bungeecord.server.[servername] permission.
You can proceed to add as many servers as you'd like, in our case, we will add the hub and smp.
hub: motd: 'My hub server!' address: localhost:20001 restricted: false smp: motd: 'My smp server!' address: localhost:20002 restricted: false
Now, let's continue with the other components of your bungeecord's config.yml file -
motdÃ‚Â - Is used to set your message of the day for the proxy server. Since your players will be connecting to the proxy server first, the MOTD you set here is what players will see in their server list!
prioiritesÃ‚Â - When a player connects for the first time or ifÃ‚Â
forcedefaultserveris enabled then BungeeCord goes through this list of servers from top to bottom and tries to forward the connection to each of them. So if you would like to support multiple client versions, simply specify at least one server per version and BungeeCord will do the matching for you. Here is an example -
prioirties: - hub - smp
hostÃ‚Â - In this section, put your server IP followed by your port. For example,Ã‚Â
max_playersÃ‚Â - The max player limit shown in the minecraft client's multiplayer menu. Note that this limit is fake, you can set it to 0, players will still be able to join. Look at player_limit above for a "real" player limit.
ip_forwardÃ‚Â - Whether to allow IP or UUID forwarding. Recommended to set to true for online mode servers.
These are the settings you can tweak for your bungeecord server. Once you've adjusted the values according to your preference, save the file, and restart the server. Now we will set up the backend servers.
Setting up the backend servers
Setting up backend servers are rather simpler compared to the proxy setup. The following values need to be set, and your backend servers will be configured to work with the proxy.
online-modemust be set toÃ‚Â falseÃ‚Â for your backend servers inÃ‚Â server.propertiesÃ‚Â file.
connection-throttlemust be set toÃ‚Â -1Ã‚Â for your backend servers inÃ‚Â bukkit.ymlÃ‚Â file.
bungeecordmust be set toÃ‚Â trueÃ‚Â for your backend servers inÃ‚Â spigot.ymlÃ‚Â file.
Once these have been configured, you can just restart your servers and everything should be setup! When in-game, all you need to do to switch between servers is by using the command /server followed by the server name you want to go to!
Make sure you're a server operator while performing this command!
In the event the proxy doesn't work, check these points for fixing the common issues people face while setting it up.
If you get an Ip forwarding error while connecting, setÃ‚Â
ip_forwardtoÃ‚Â trueÃ‚Â inÃ‚Â config.ymlÃ‚Â of your proxy server.
If you've connected, but cannot switch to other servers with the error of "Could not connect to a default or fallback server", then ensure that your backend server is turned on and running!
if you can't ping your proxy server in the server list, be sure to check that the host ip address inÃ‚Â config.ymlÃ‚Â is configured properly, and that your connection throttles and timeout time is altered accordingly!