Bare Server

Starters

So, where should we create the server? Do it somewhere you'll remember. I recommend creating a folder here mkdir -p /home/minecraft-servers && cd /home/minecraft-servers

Java

No matter what server hosting software you use, it all wraps around the Java Dedicated Server (JDS) created by Microslop. The jar file is everything a server needs to run, and all the third party software just wraps around it. From AMP to Playit.gg, everything uses the jar the same way. So, how do you do it? First, I assumed you installed Java from the previous page? No? Well, then run sudo apt install default-jdk Just be aware for different versions of Minecraft, different versions of Java will be needed. Now, create a folder with a name for your server. mkdir example && cd example for... example. Now, run wget https://piston-data.mojang.com/v1/objects/33680f5f2ac32864d6d7cf5e56a705fdb3e05f4c/server.jar that will download the server.jar file. If the link ever fails, go back to the main page I sent earlier and copy the download link from there. The server jar file on the Mojang site is only the latest release. At the time of me writing this, that is 26.3. To search specific versions, you'll need a site like mcversions.net. Just search the desired version and copy the download link and use the wget command. Run ls in your terminal to verify the jar downloaded. I've had issues with fabric we'll get into the modded section about. If it says something other than server.jar, keep note of its name. To start the minecraft server, run java -Xmx4G -Xms4G -jar server.jar and as I said, if it's something other than server.jar, just replace the command with the file name. the -Xms2G -Xmx4G are for ram allocation. It's in either Gib or GB, I do not remember. If you desire to change it, just put a different number. I just put -Xmx1G -Xms10G to give it enough memory. When you run the jar, it'll say "you need to agree to the EULA first." Now run ls and you should see a lot more files. For me, I see five aditional files; one of them being the EULA. Simply run nano eula.txt and change the "false" to "true". The EULA is essentially a terms and conditions for a server. When you save and exit, start the server again and it should run with no issues. If you stop the server by pressing ctrl+c and list the directory again, you'll see a world folder now too. As long as you keep that terminal open, the server will run and you will be able to connect. But what if you close that? You could use GNU Screen, but this way is much better. Run nano /etc/systemd/system/EXAMPLE.service Just replace the example part with your name of choosing. I recommend doing something like your server name followed by mc. Example: example-mc.service In there, paste this:

[Unit]
Description=Bare Metal Minecraft Server
After=network.target

[Service]
Type=simple
User=root
WorkingDirectory=/home/minecraft-servers/EXAMPLE/
ExecStart=java -Xms1G -Xmx10G -jar server.jar
Restart=always
RestartSec=15

[Install]
WantedBy=multi-user.target
      
Just replace the -Xms1G -Xmx10G with your desired memory allocation, the EXAMPLE to your folder name, the description to something different, and if you want and the jar name to whatever it's called if its different. Save, exit, and run sudo systemctl daemon-reload && sudo systemctl enable example-mc.service && sudo systemctl start example-mc.service && sudo systemctl status example-mc.service Just replace the example with your desired name. if it says "active" and/or "running", it worked. If not, something went wrong and I cannot help you. Best advice I have if it fails is to double check config. Your server is all ready to go now! All there is left to do is familiarize yourself with the server properties file and to join the server and have some fun with friends (assuming you did the port forwarding guide too. If not, that's next. Click here to follow that).

Modded Server

A modded server is pretty much the exact same setup. Just search up on Google "fabric dedicated server" or whatever your desired mod loader is. I do fabric, so just click here to go to the download page. Fabric's jar file is weird though. If you click download, it'll download the jar file properly named and formatted. But if you do wget, it will download it as a binary simply called "jar". It'll still run, I'd just recommned renaming it mv jar fabric.jar To start the server, same command as the standard command I showed earlier, just with the fabric jar. It'll create a directory for mods where you put your mods. To do that, you can either use wget or SFTP. If you haven't setup SFTP, read the section in Jellyfin about it.

Bedrock

The Bedrock Dedicated Server (BDS) works a little differently compared to the JDS. The BDS is compiled in C++ which is a language that can run standalone on its own with no coding language needing to be installed to run it. Let's create a folder first. mkdir -p /home/minecraft-servers/bedrock_example && cd /home/minecraft-servers/bedrock_example Now, you need to download the zip. You can download it from the Bedrock Server Download page or run wget https://www.minecraft.net/bedrockdedicatedserver/bin-linux/bedrock-server-1.26.51.1.zip -O server.zip && unzip server.zip && rm server.zip && ls You should see all the needed folders and config. You will also see a how to html file. If you would like an easier way to read it, you can here. What's interesting about the BDS compared to the JDS is that the JDS works the same on Windows and Linux, while the BDS does not. As you saw on the downloads page, there's Windows support, and Ubuntu support and states that no other distros are supported. I think other distros will work, they just will not do support tickets for it. This works this way because of the coding languages. The JDS is programmed in Java while as I mentioned the BDS is coded in C++. C++ is a language that requires a lot more tweaking and is made to be a lot more specific. This makes it good for micro managing stuff like memory leaks, but makes it a pain when trying to port it to a different system. Take a look at Minecraft on Linux. Java is fully supported, Bedrock is not. Because Mojang has no interest in making a dedicated version of Bedrock for Linux because it would be a lot of work when most people don't use Linux. TL;DR C++ is not as portable of a language as Java. Stuff like Steam uses a compatibility layer for Linux gaming, so I have no clue why Mojang doesn't. Seriously, on the Minecraft Launcher for Linux, it states Dungeons and Legends are not available on Linux but work on Steam just fine. Anyway... that was a tangent, let's get back to it. To start the BDS, run the command LD_LIBRARY_PATH=. ./bedrock_server Now let's create the background process. Create the config like earlier nano /etc/systemd/system/EXAMPLE.service and paste this:

[Unit]
Description=Bare Metal Minecraft Server
After=network.target

[Service]
Type=simple
User=root
WorkingDirectory=/home/minecraft-servers/EXAMPLE/
ExecStart=LD_LIBRARY_PATH=. ./bedrock_server
Restart=always
RestartSec=15

[Install]
WantedBy=multi-user.target
      
Change the name to your directory, and edit the description if desired. Save and exit, run sudo systemctl daemon-reload && sudo systemctl enable example-mc.service && sudo systemctl start example-mc.service && sudo systemctl status example-mc.service Just replace the example with your desired name. Your bedrock server is now running in a backgroung process. I do wanna also mention that Bedrock server worlds are folders like Java's worlds. If you want to add a prexisting bedrock world, you just need to change it from a .mcworld to a .zip and extract it. If you ever want to get it back to a .mcworld file, put the folder back in your bedrock saves on your PC and open up the game. I've tried this before, sometimes the world didn't let me join, sometimes it did. If you can't join, just click export and you'll get the .mcworld file and then simply import it back into Minecraft.

Other Info

I might make my own Minecraft server manager now that I think of it... maybe, maybe no. Would be a fun challenge, probably easier than SpyderFly.

One thing I setup with a server I once used a python script that will take a backup each time someone leaves. It's right here if you would like to use it.

Quick Navigation

  • Prerequisites
  • Configuring the OS
  • Minecraft Server
  • Jellyfin
  • Nextcloud
  • Nextcloud LEMP stacks
  • Tailscale
  • Port Forwarding
  • HTTPS Configuration
  • SpyderFly
  • Recommended Tools
  • Back To Homepage

    Other info

    Any issues with this guide, shoot me an email "[email protected]"

    Date created: September 25th, 2026

    Last modified: September 25th, 2026

    this site is open source