Advance

A Clever Guide for Install a Minecraft Server on CentOS 7

Richard 7 Min Read
A Clever Guide for Install a Minecraft Server on CentOS 7
5
(1)

Welcome to this clever guide on install a Minecraft server on CentOS 7! In a few simple steps, you’ll be able to enjoy the world of Minecraft with your friends on your own server. So let’s jump right in and get started:

Step 1: Update Your System

  • Fire up your CentOS 7 terminal.
  • Type the command: “sudo yum update -y” (without quotes) and hit Enter.
  • This will update your server’s software packages to ensure a smooth installation process.
Recommended Service: Buy Linux VPS

Step 2: Install Java Development Kit (JDK)

– Minecraft requires Java to run, so let’s install it.

sudo yum install java-1.8.0-openjdk -y

– CentOS will fetch and install the Java Development Kit for you.

Step 3: Create a Dedicated User for Minecraft

– While you can run Minecraft as the root user, it’s best practice to use a dedicated user for security reasons.

sudo adduser minecraft

– You can choose a password for the new user or leave it empty for passwordless access (optional).

Step 4: Grant Administrative Privileges to the Minecraft User

– To grant administrative privileges to the Minecraft user, add them to the “sudoers” group.

sudo usermod -aG wheel minecraft

– This will allow the Minecraft user to execute administrative commands if required.

Recommended Article: How To Install And Uninstall Virtualizor On CentOS 7

Step 5: Download and Install the Minecraft Server

– Switch to the Minecraft user by typing: “su minecraft” and pressing Enter.

– Download the official Minecraft server file using the command:

wget -O minecraft_server.jar https://www.minecraft.net/en-us/download/server/

– Once downloaded, start the server for the first time using:

java -Xmx1024M -Xms1024M -jar minecraft_server.jar nogui

– This will initialize the server and generate the necessary configuration files.

Step 6: Accept the End User License Agreement (EULA)

– After starting the server, your terminal will display an EULA agreement link.
– Open it in a web browser, read the agreement, and at the end, change “eula=false” to “eula=true” in the eula.txt file using: “nano eula.txt”.
– Save the changes and exit the nano editor by pressing “Ctrl + X“, then “Y“, and finally, Enter.

Step 7: Modify Server Properties (Optional)

– To customize your server experience, open the server.properties file using:

nano server.properties

– Adjust various settings such as game mode, maximum players, world size, and more.

– Save the changes and exit the nano editor.

Step 8: Start the Minecraft Server

– Execute the following command to start the server:

java -Xmx1024M -Xms1024M -jar minecraft_server.jar nogui &

– The “&” at the end ensures the server runs in the background.

Congratulations! Your Minecraft server is now up and running on CentOS 7. You can invite your friends to join by sharing your server’s public IP address. Remember, you might need to forward the Minecraft port (default: 25565) in your router to enable external connections.

Disclaimer: This guide assumes general familiarity with Linux command-line interfaces. Please follow the steps carefully to avoid any issues or unintended consequences.

How useful was this post?

Click on a star to rate it!

Average rating 5 / 5. Vote count: 1

No votes so far! Be the first to rate this post.

View More Posts
Richard
Eldernode Writer
We Are Waiting for your valuable comments and you can be sure that it will be answered in the shortest possible time.

Leave a Reply

Your email address will not be published. Required fields are marked *

We are by your side every step of the way

Think about developing your online business; We will protect it compassionately

We are by your side every step of the way

+8595670151

7 days a week, 24 hours a day