This article explains how to set up a multiplayer server in Minecraft Java Edition. This time it is the first time, so I will explain up to the point of building the basic Minecraft server.
This time we will build a server using CentOS7. I want at least 2GB of memory to use for the server. The amount of memory allocated can be changed later according to the number of people connected. Since it is a server, high GPU performance is not required.
First, download the necessary files.
First, download the Jar file to be placed on the server. There is an official version and a modified version such as Bukkit and Spigot, but in this article I will try to build a server using Spigot. If you have your own software, you can use it. The difference between the official version and the modified version is whether or not the plugin can be installed. Of course, if you can use the plug-in, you can take measures against vandalism, so it is recommended to use the modified version.
For convenience, rename the Jar file you downloaded earlier to "spigot.jar".
Here, FTP software called FileZilla is used. FTP software is software for sending and receiving files between a server and a work PC. It is mainly used here to transfer files related to Minecraft to the server.
Transfer the Spigot Jar file you downloaded earlier using FTP software.
After starting FileZilla, connect to the server. Enter the IP address or domain for the host (H), the user name [root] for the user name (U), and the password set for the user for the password (P). The task here is to log in to the server from the FTP software.
This time, we will create a new directory called "Minecraft" in the "root" directory and build a Minecraft server in it. After creating and moving "Minecraft", upload the Jar file you downloaded earlier to the Minecraft directory. This completes the FTP operation.
Now connect to the server using SSH. It can be accessed using TeraTerm for Windows and the terminal installed from the beginning for Mac.
Copy and paste the following commands in order. Replace [IP address] with the IP address or domain of the server.
# ssh -l root [IP address]
Install Screen. It keeps Minecraft running in the background for 24 hours.
# yum -y install screen
Then install Java. Without it, Minecraft won't work on the server.
# yum -y install java-1.8.0-openjdk
Work with the server connected via SSH. Here, we will do the port release work required to publish the server in Minecraft.
Release port 25565 required for communication with Minecraft.
# firewall-cmd --zone=public --add-port=25565/tcp --permanent
Reflect the settings by reloading
# firewall-cmd --reload
Finally start Minecraft.
Change to the directory where you placed the Spigot Jar file.
# cd /root/Minecraft/
Launch Minecraft
# java -Xmx1024M -Xms1024M -jar spigot.jar
This completes the initial startup. The necessary files are generated at the first startup.
If you log in with FTP software again and look at the / root / Minecraft / directory, you will find "eula.txt" in the file generated earlier. Download this file to your work PC and open it with Notepad or TextEdit.
In the bottom line
eula=false
Where it is
eula=true
Rewrite to. Save the file and replace /root/Minecraft/eula.txt with the edited file by FTP.
Make an SSH connection again.
# ssh -l root [IP address]
# cd /root/Minecraft/
# screen
The following is the Minecraft startup command, but the following command allocates 2GB (2048MB) of memory. If you want to change the amount of memory allocated, you should change this number at startup. "Xms" represents the maximum memory used, and the load on the memory can be reduced by setting "Xmx" and "Xms" to the same value.
java -Xmx2048M -Xms2048M -jar spigot.jar
Prepare a Minecraft client and try entering from the PC side. Enter the IP address or domain of the server in "Server address".
In the initial state, no player has the authority, so execute / op [your MCID] from the console to give the authority to yourself.
If you want to stop the server, you can stop it with the / stop command from within Minecraft. It's basically running on the Screen, so it doesn't stop for 24 hours.
This time I used Spigot to build a Minecraft multi-server. Next time, I will play with detailed settings. Next article Click here for the second article
Recommended Posts