Raspberry Pi Minecraft Server Script With Startup Service 1.13

Minecraft Update Aquatic
Minecraft Update Aquatic

Based on the comments and feedback from my older guides I have added many requested features and fixes. It has changed so much since 1.12’s World of Color that my old guide is now obsolete and it’s time for the 1.13 Aquatic era update!

This script and guide are written to help you get a great performing Raspberry Pi Minecraft server up and running in only a few minutes.

I play on my server with 3-4 players on Survival mode without any difficulty on default settings (vanilla view distance of 10 and normal entity spawns/ranges). Above that number of players you will want to look into hardware with more memory but if you just want to play with a few friends it will be an excellent experience!

Status Update On Minecraft 1.14.2 (June 1st 2019)

The current official release (1.14.2) continues to be very unstable for the Minecraft community. Servers continue to suffer from TPS drops, the entire server freezes for a good 10-20 seconds whenever the world saves, and a multitude of other stability and performance issues continue to occur despite the 1.14.1 and 1.14.2 point releases already being released to try to tackle them.

In a nutshell, the current performance of the new version is actually literal garbage and the entire 1.14 branch should be considered in beta at this stage even if it’s “officially” released.

Nevertheless, many of you (and myself) wanted to try it anyway so I have made it available in the setup script as the “development” branch. The “stable” branch is still 1.13.2. Be advised that at this time it will be a laggy and crashy experience (just check out the comments at the bottom of this post from those who have tried it) whereas the 1.13.2 stable branch is basically perfect.

If you want to try it anyway make sure you have a backup of your server first. You cannot go back after you upgrade the server without restoring a backup. Once the 1.14 features are put into your server data loading it in 1.13.2 will result in non stop crashes.

I will further update this post as the situation evolves. The Paper developers are incredibly good and I have no doubt that it is only a matter of time before they fix Mojang’s product yet again!

Features

  • Sets up fully operational Minecraft server in a couple of minutes
  • Raspbian / Ubuntu / Debian distributions supported
  • Installs and configures OpenJDK 9 (or OpenJDK 11 if available)
  • Sets up Minecraft as a system service with option to autostart at boot
  • Automatic backups to minecraft/backups when server restarts
  • Updates automatically to the latest version when server is started
  • Easy control of server with start.sh, stop.sh and restart.sh scripts
  • Optional scheduled daily restart of Pi using cron
  • Optional configuration of video memory to 16MB (default 64MB) and overclocking MicroSD reader to 100Hz (default 50Hz) for maximum performance

Requirements

  • Raspberry Pi model with 1024MB of RAM. Basically a Raspberry Pi 2B or higher. (No Zero unfortunately, 512MB is not enough RAM to do this, I’ve tried!)
  • Headless Linux distribution such as Raspbian Stretch Lite, Ubuntu Server 18.04.2, or any Debian based distribution (GUI distros can be used at the expense of available RAM and server performance)
  • Solid state drive highly recommended but not required.
    You can get a SSD setup on a Pi for less than most Micro SD cards cost. See my article here for details
  • If using MicroSD you want to be using a mid to high range card otherwise you will really be hurting on IO when the server is reading/writing chunks of terrain. Your card’s name should have lots of Pros/Ultras/Extremes in the title! Click here for MicroSD card benchmarks/recommendations.

Recommended Gear

Raspberry Pi 3B+ with 2.5A Power Supply

Sabrent USB 3.0 to SSD / 2.5-Inch SATA Adapter -AND- Kingston A400 SSD 120GB SATA 3 2.5โ€ Solid State Drive

Or for a compact setup: SanDisk Extreme Pro 128GB USB Solid State Flash Drive

Choosing a Linux Distribution

The most important consideration when choosing which flavor of Linux to run the server on is simple: available RAM. Headless Linux distributions such as Raspbian Lite that don’t have a built in GUI have substantially more memory available for the Minecraft server.

Our biggest obstacle when running a Minecraft server on the Pi is available RAM since 1 GB is extremely low for this type of server. To have a playable experience you should not be running anything else on the Pi so all memory is available to be used.

After testing on many different distros I am finding Raspbian Lite and Ubuntu Server 18.04.2 32-bit to be the best choices. These distributions come with very few background processes and have rock solid support and performance.

64-bit vs 32-bit

There’s a lot of discussion in the Pi world about the up and coming aarch64 64-bit distributions vs. armhf 32-bit distributions. They have been and continue to improve dramatically. There are already use cases where 64-bit is far superior such as video encoding, advanced compression, etc.

So how about for running a Minecraft server? I have been testing extensively with Ubuntu Server 18.04 64-bit and the Debian Buster 64-bit. I have consistently had worse performance and stability than on 32-bit versions of the exact same distros.

But how can that be? It’s certainly true that Minecraft servers benefit in CPU performance from 64-bit versions of Java. The answer is actually incredibly simple: memory. The server running on a 64-bit Java Virtual Machine uses a minimum of about 100 MB more memory. This makes perfect sense because 64 bits > 32 bits by definition!

The Raspberry Pi’s 1 GB of memory has been the biggest obstacle for this project since the very beginning. Back when I first went into the Paper Minecraft developer IRC room and told them what I was trying to do I was practically laughed out of the chat room for even thinking of trying this. Most Minecraft server branches including vanilla can’t even start on the Pi because of the limited memory.

For a dedicated Minecraft server on the Pi I very highly recommend staying 32-bit. You will have more available memory which means it will be much faster and more stable. Since memory is our bottleneck the increased CPU throughput does not help us and losing *any* of our memory is disastrous!

If the Raspberry Pi 4 has more memory like we all expect it to this recommendation will change completely. Even 2 GB of memory would make the extra memory that 64-bit uses a non-issue and the CPU throughput performance gains very desirable. For now though stay 32-bit for a Minecraft server!

Tested Distributions

Raspbian Lite – It’s Raspbian. It has very low memory usage and is the official distribution of the Raspberry Pi. The server runs very well on this. One downside is it does not have packages for OpenJDK 11 (OpenJDK 9 is the newest one in the Raspbian repository at time of writing). It’s overall a great choice.

Ubuntu Server 18.04.2 – Ubuntu Server is my favorite Linux distro. I use it for nearly all of my projects. The performance of the 32-bit armhf version is on par and in some ways superior to Raspbian due to the availability of OpenJDK 11 on Ubuntu. It’s a fantastic choice! Click here for my Ubuntu setup guide for Raspberry Pi. The 64-bit version is not a fantastic choice and not recommended because of the higher memory usage. Stick with 32-bit and you’ll be a happy camper with Ubuntu Server.

Debian Buster 64-bit – Debian is the distribution Raspbian is based on. This version is a preview of Debian “Buster” which is the successor to Stretch and will be the next version of Raspbian when it is released. I like this distribution but it is currently still unofficial and unsupported. Performance and stability was less than Ubuntu and Raspbian.

Benchmark Your Storage

Make sure your storage is running fast enough to be an effective Minecraft server. I wrote a benchmark for this purpose to make this extremely easy. To get accurate results make sure nothing is running when the benchmarking is taking place.

Run the benchmark by pasting/typing:

sudo systemctl stop minecraft
curl https://raw.githubusercontent.com/TheRemote/PiBenchmarks/master/Storage.sh | sudo bash

Ideally you will score around 1000 for a good quality Micro SD card (and much higher for solid state storage). A low score (< 700) here indicates here that it is probably time to upgrade to a solid state drive or a faster Micro SD card. Click here to view all the existing benchmarks.

You can still run the server if you’d like with a low storage score but be advised when operations like saving the server’s blocks take place the people online may experience quite a big of lag!

Installation

SSH into your Raspberry Pi and paste the following commands:

wget https://raw.githubusercontent.com/TheRemote/RaspberryPiMinecraft/master/SetupMinecraft.sh
chmod +x SetupMinecraft.sh
./SetupMinecraft.sh

The script will setup the Minecraft sever and ask you some questions on how to configure it. I’ll explain here what they mean.

“Set clock speed to 100 MHz? Requires reboot. (y/n)?” – Highly recommended but at your own risk. This will overclock your MicroSD card reader for you to 100 MHz giving you much faster read/writes on your server.

There are some cards (usually cheap ones) that can’t handle this overclock and will fail to boot afterward. If this happens don’t panic! You can simply undo the overclock by connecting the MicroSD/SSD to your computer and removing the line dtparam=sd_overclock=100 from /boot/config.txt. Save and reboot the Pi. Run MinecraftSetup.sh again and choose ‘no’ the next time.

“Change GPU shared memory to 16MB? Requires reboot. (y/n)?” – This is recommended for everyone. Unless you are running on a GUI distro you would be crazy not to do this! Since we are running a headless lite distribution we don’t need any more than the bare minimum of 16MB. That extra memory makes a gigantic difference when we are only working with 1 GB total.

“Enter amount of memory in megabytes to dedicate to the Minecraft server” – The amount of memory that will be dedicated to the Minecraft server. The more the better, but you must leave some room for the operating system background processes.

If you exceed the total available memory either the server will crash or the Pi will get incredibly slow to the point where your SSH session will start timing out. The setup script will make a recommendation to you which is your available memory – 10% for headroom. If you aren’t sure what to put just go with the recommended amount.

“Start Minecraft server at startup automatically (y/n)?” – This will set the Minecraft service to start automatically when your Pi boots. This is great because whenever you want to play you can just plug it in and go without having to SSH in.

“Automatically reboot Pi and update server at 4am daily (y/n)?” – This will add a cron job to the server that reboots the Pi every day at 4am. This is great because every time the server restarts it backs up the server and updates to the latest version. See the “Scheduled Daily Reboots” section below for information on how to customize the time or remove the reboot.

That is it for the setup script. The server will finish configuring and start!

First Run

The first time you run the server it will take a little longer to start since it is generating all the server data. If you try to log in before it fully starts you will get a connection timeout error. Watch for the line: “Timings Reset”. This is the last line that prints when the server is ready to rock and roll. At this point you will be able to connect successfully.

The very first time you log into the server it will be slow for about 1-2 minutes. This is because since nobody has logged in before the server has to scramble to generate all the chunks within your view distance (10 by default) and send them to you/store them. During this time you may not be able to see very far and if you try to destroy blocks there will be noticeable lag from when they break to when they actually disappear.

Don’t panic! This will go away within a couple of minutes as the Pi catches up with all the first time login stuff it needs to do. Performance stabilizes and it will feel very much like the offline experience after that.

If you are hosting for a few friends I’d recommend logging in for the first time right after you set up the server instead of having several people nail a blank server at first startup. This gets it out of the way and when everyone is ready to log in the starting area chunks will be fully fleshed out and the Pi just has to read them. It’s an order of magnitude faster for the Pi to read chunks than to generate and store chunks.

In my experience after the initial login exploring new parts of the server doesn’t cause any lag even though new chunks are being generated. The reason for this is that when you’re walking it’s really only having to generate a new chunk as you get close to the border instead of a huge square area of chunks in all directions and all at the same time like during the first login.

Changing Minecraft Client Version

If you are wisely running the “stable” branch instead of the “development” branch there will be times where you need to select the version of Minecraft to run otherwise you will get an error message that your client is outdated when you try to log in.

Fortunately this is very easy. Open up the Minecraft launcher and instead of hitting “Play” choose “Launch Options” in the menu at the top of the window. It will look like this:

Minecraft Launcher “Launch Options” Tab

Click the “Add new” button and pick which version you want to add. You can optionally gave it a name or just click save.

Now when you go back to the “News” tab you will see a dropdown arrow where you can select which version of Minecraft you want to play!

Start, Stop and Restart Server

The server can be started, stopped and restarted two different ways. You can use the provided scripts in the Minecraft folder or you can use systemctl. Here are the commands:

cd ~/minecraft
./start.sh
./stop.sh
./restart.sh

-OR-

sudo systemctl start minecraft
sudo systemctl stop minecraft
sudo systemctl restart minecraft

Automatic Backups

The server backs up each time it starts. This helps you recover easily if something goes wrong. This system works best if you configured the server to restart daily since it means you will have a backup every day.

To access these backups type:

cd ~/minecraft/backups
ls

When a backup is made the filename will be the date and time the backup was taken. If you need to restore a backup it’s very easy. Substitute the timestamp in my example to the backup you want to roll back to. Type:

cd ~/minecraft
./stop.sh
rm -rf world world_nether world_the_end
tar -xf backups/2019.02.15.22.06.30.tar.gz
./start.sh

Your world has now been restored! It’s a good idea to download these backups off the Pi periodically just in case the Pi’s storage fails.

Scheduled Daily Reboots

The daily reboots are scheduled using cron. It’s very easy to customize the time your server restarts.

To change the time that the server restarts type: crontab -e

This will open a window that will ask you to select a text editor (I find nano to be the easiest) and will show the cronjobs scheduled on the Pi. The Minecraft one will look like the following:

0 4 * * * /home/ubuntu/minecraft/restart.sh

There are 5 fields here. The default restart time is set to reboot at 0 minutes of the 4th hour of the day (4 AM). The other 3 fields are left as * to represent every day of every month. Make any desired changes here and press Ctrl+X to exit nano and update the cronjob.

To remove the daily reboot simply delete the line and save.

Installing Plugins

The server supports plugins that are compatible with Bukkit / Spigot / Paper. A popular place that you can get plugins is at https://dev.bukkit.org/bukkit-plugins where there are thousands of them!

To install a plugin you simply download the .jar to the minecraft/plugins folder and restart the server. For example, WorldGuard is a very popular plugin that lets you add protection to different areas of your server.

To install this plugin on our Minecraft server we would use the following commands:

cd ~/minecraft/plugins
wget https://dev.bukkit.org/projects/worldguard/files/latest
sudo systemctl restart minecraft

The server will restart and the plugin will be installed. It’s that simple! To use the plugin refer to the documentation on the plugin download page to find out which commands you use to configure/interact with it.

Warning: be advised that plugins are the #1 issue for performance degradation on Minecraft servers. This isn’t because all plugins are bad. Some plugins are coded very inefficiently or perform features that require a lot of hooks in the code.

You should be careful about what plugins you install on the server and if you start having bad performance disable your plugins one by one until you find the culprit!

Reconfigure / Update Scripts

The scripts can always be reconfigured and updated by downloading the latest SetupMinecraft.sh and running the installer again. It will update all of the scripts in the Minecraft directory and reinstall the startup service for you.

Running SetupMinecraft.sh again will also give you a chance to reconfigure options such as the memory dedicated to the server, daily reboots, starting the server on boot, etc.

This will not overwrite your world or any other data so it is safe to run!

Port Forwarding

If everyone on your server is on the same LAN or WiFi network as you then you don’t need to do this. If you want people to connect from outside your local network then you need to set up port forwarding on your router.

The process for this is different for every router so the best thing to do is just look at your router and find the model # and put that in google with port forwarding for easy instructions on how to do it for your specific router.

You want to forward port 25565. The type of connection is TCP if your router asks. Once you do this people will be able to connect to your Minecraft server through your public IP address. This is different than your local IP which is usually a 192.x.x.x or 10.x.x.x. If you don’t know what that is just go to google and type “what’s my ip” and Google will kindly tell you!

Wired vs. Wireless

Going with an ethernet (wired) connection is going to be faster and more reliable. There’s so much wireless traffic and other interference in the air that running your server on WiFi is not recommended.

Even if it is working great 99% of the time it can ruin your experience very quickly if the WiFi drops for a couple of seconds and you get blown up by a creeper!

All that being said, the server works fine on wireless. The script will work fine as is with a wireless connection.

Conclusion

OpenJDK 9’s new garbage collector has made running a server on the Raspberry Pi feel great! We can run at the default view distance of 10 with default entity settings.

If you have any feedback or suggestions let me know in the comment section. A lot of the new developments in this script were directly from comments to the older articles.

Have fun!

115 thoughts on “Raspberry Pi Minecraft Server Script With Startup Service 1.13”

  1. Hello! Thank you so much for making this guide! This helped so much! I was wondering though, do you know of a way to add plugins to the server and choose a map? I know there are other ways that include those options, but they didn’t work for me, and this was a lot simpler! Thank you so much for your help, have a nice day!

    1. Hey Puppy,

      Glad you enjoyed the guide!

      The good news is that this server supports plugins. The server supports Spigot/Bukkit plugins. There’s tens of thousands of them! https://dev.bukkit.org/bukkit-plugins and https://www.spigotmc.org/resources/categories/bukkit.4/ are two good repositories of plugins. Installing these is pretty much as simple as downloading the plugin and extracting it to your ~/minecraft/plugins directory.

      As far as choosing maps there’s a few different ways to do it. The most popular way is by specifying a seed. If you browse Google for Minecraft 1.13 seeds you can get a bunch of them. To you use a seed you will go to the minecraft directory and edit server.properties by typing nano server.properties. In that file you will see a line that looks like seed=x. If you put the seed in here before you start your server it will generate that world from the seed! You can also use programs such as MCEdit to edit the world in a map editor and use that for your server.

      Let me know if you run into any trouble or have any more questions!

      -James

  2. What a fantastic script, thank you.
    After the 1st reboot that followed on from things like overclocking the SD card, a server was up and running with the server output appearing on the screen and accepting commands as expected. The option to overclock the SD card, automatically run the server at startup and doing the reboot at 4am were all accepted.
    But after closing the Raspberry Pi 3B+ down after the next switch on I can’t see the server running and can’t find it to play. The IP address of 192.168.0.149 was checked, and I saw that about 15 seconds after the command prompt appeared, the cursor moved to the far left (instead of being after the $ sign), and “screen -r minecraft” failed to find a screen to resume.
    Running ./start.sh did start the server.
    I admit to installing the GUI then using raspi-config to boot to command only before doing the server installation. Is this the cause of the server not runing at bootup?

    1. Hey Greenbandit,

      I downloaded Raspbian full to do some testing and found some problems in the script when ran on Raspbian full vs. the Lite version. This has to do with how the networking services start in full vs. lite.
      I have updated the scripts with several fixes thanks to your feedback. This will improve reliability on both versions. If you download the latest SetupMinecraft all the fixes are in there!

      -James

      1. James,
        That has sorted it on my system. This is awesome.
        I can now install Raspbian (Full), then use raspiยญconfig to get the Raspberry Pi to boot to command before running your setup script thus giving me the ability to go back to the desktop between minecraft sessions to edit files or whatever if I ever want to (because I am not that good at using the command line for the clever stuff). And the minecraft server now runs as intended after a reboot.
        Here’s an idea. My router is set to have a limited DHCP address range to leave room for fixed IPs on my LAN, so since I am aiming towards leaving the Pi on 24/7 for my boys I manually edited /etc/dhcp.conf to give eth0 & wlan0 a fixed IP address. Would it be worthwhile adding such an option to the setup script to ensure that the IP address doesn’t ever change? Since I didn’t setup my wifi during the initial Raspbian setup, the (commented out) wlan0 section in /etc/dhcp.conf was not created, but it did work when manually added.

  3. Hi, when going through the setup, it always ends with “Setup is complete. Starting Minecraft server…” pauses for a few seconds, and then says
    “There is no screen to be resumed matching minecraft.” Any ideas?

  4. “Setup is complete. Starting Minecraft server…
    There is no screen to be resumed matching minecraft.”
    Help! I have tried executing start.sh a couple times, but the server never seems to start. Any help is appreciated.

    1. Hey Wyatt,

      Let’s find out! There’s two log files and one of them should tell us what is going wrong. Go ahead and do a
      cd ~/minecraft/logs and then do:
      nano latest.log

      The other log can be viewed by typing sudo journalctl -u minecraft. I don’t suspect you’ll see anything unusual in this one since it sounds like it is making it to the end of the start.sh script.

      Let’s see what it says in your latest.log file. Can you also post which Pi you are using?

      Thanks,
      -James

  5. James,
    I remain grateful for your setup script.
    A RPi minecraft server received a lot of use last weekend from 4 LAN players and it has worked great. In contrast to a previous setup based on a vanilla server, this didn’t show signs of lag even with the view distance at the default 10 whereas the vanilla server needed the view distance at 6 to make it playable on the world we were using.
    But I’m puzzled why backups are not working. I can see the “mkdir backups” line in the setup script, but there was no backups directory until I manually created one. After a 4am reboot though, there is no backup visible to user=pi in /minecraft/backups. Is this my finger trouble? Out of interest, which part of the scripts is it that makes the backup?

    1. Hey again Greenbanditz! I’m glad it’s working great on vanilla settings! That was my experience as well as before Java 9 came out I had to turn down the view distance and some other settings to get good performance.

      The backup is made in start.sh with this line:

      # Create backup
      echo “Backing up server (to minecraft/backups folder)”
      tar -pzvcf backups/$(date +%Y.%m.%d.%H.%M.%S).tar.gz world world_nether world_the_end

      Can you check your start.sh and make sure that it has this line? If you had updated from a previous version it may not have pulled it down from the github repository.

      If your start.sh is missing that line download the latest SetupMinecraft.sh which now will update all of the scripts in the Minecraft directory. This will get everything up to date!

      There is one other possibility. Did you change the world name of your world? It assumes that your folders are world, world_nether and world_the_end. If you have changed it I may need to add a line that reads from server.properties what the world name is so that if people are changing it then backups are still taken.

      -James

      1. James,
        Sorted.
        I had an earlier start.sh that did not have the backup line in it, it was not a problem due to a renamed world.
        I now have backups being made to the SD card. Backups to a USB stick is the next task to ensure the world is not lost if the SD card goes down. ๐Ÿ™‚

        I remain really grateful for your help and excellent scripts.

        1. Awesome! That’s definitely the best way to do it. I may update the script to let people choose a backup directory to make setting this up easier in the future but I’m glad you got yours working!

          -James

  6. Hey James, this is great and I’m loving that I can host a server on my Pi instead of keeping my beefy PC running. Now my friend and I have a game we can play together, and he can log on whenever he likes.

    I’m using with the Lite version as recommended, but found that my server does not start automatically at startup anymore. I couldn’t find a file in the ~/minecraft directory where these settings would be – any advice? Should I just try reinstalling?

    1. Hey Kieran,

      I have fixed this in the latest version. It broke due to a broken ca-certificates-java package in Raspbian. I’ve just added the capability for SetupMinecraft to update your scripts to the latest version without reinstalling.

      Simply do:
      cd ~
      rm SetupMinecraft.sh
      wget -O SetupMinecraft.sh https://raw.githubusercontent.com/TheRemote/RaspberryPiMinecraft/master/SetupMinecraft.sh
      chmod +x SetupMinecraft.sh
      ./SetupMinecraft.sh

      This will update all of the start/stop scripts to the latest version. It will also reinstall the startup service. If it is still having trouble we will dig a little deeper by checking ~/minecraft/logs/latest.log.

      Let me know how it goes!
      -James

      1. You’re a legend, James! The server didn’t end up rebooting at 4AM, but that’s fine for me now because I don’t have to manually restart it myself at 4AM. I’ll keep it running and see what happens overnight to see if it restarts this time.

        1. That’s awesome to hear Kieren, keep us posted!

          Make sure your Pi isn’t still set to the wrong time zone (I think the default time zone is the UK)

  7. Hello James,
    I also suffer from the “There is no screen to be resumed matching minecraft”-problem. The server was running fine for some weeks and then stopped to work at all (after some stupid server “maintenance” . Never touch a running system…).
    I tried a new install on a blank SD-card and a fresh download of raspbian lite but there seems to be a problem with the installation of java. Again “… no screen …” but without a working java there will be no server running and therefore no screen to resume…
    I hope the java-issue will be fixed soon.
    You did a great job! Thank You! Without Your work I wouldn’t ever have set up a minecraft server on a RaspberryPi.

    1. Hey Achim,

      I found the problem. It turns out there is a problem with the Raspbian ca-certificates-java package right now and it’s not installing correctly. Specifically it gives: Error: missing `client’ JVM at `/usr/lib/jvm/java-9-openjdk-armhf/lib/client/libjvm.so’.

      I have just committed a workaround to SetupMinecraft.sh. Do a:

      rm SetupMinecraft.sh
      wget -O SetupMinecraft.sh https://raw.githubusercontent.com/TheRemote/RaspberryPiMinecraft/master/SetupMinecraft.sh
      chmod +x SetupMinecraft.sh
      ./SetupMinecraft.sh

      and Java will now install correctly! The workaround specifically was a soft link from the client to the server JVM folder. The SetupMinecraft script now does this for you but the manual fix is:
      sudo ln -s /usr/lib/jvm/java-9-openjdk-armhf/lib/server /usr/lib/jvm/java-9-openjdk-armhf/lib/client
      sudo apt-get install openjdk-9-jre-headless -y

      Thanks for reporting the issue!

  8. Hey James,
    Your solution works fine for me. I used the manual fix on my server and a friend of mine set up a new server which also works out of the box.
    Thank You! We really appreciate the way You share Your knowledge with us.

    1. Hey Arne,

      Did you sudo when you installed the script? It can be ran as root and will go into the root folder if you sudo or run the Setup as root. The intended location is your user’s home folder (~).

      If you didn’t run the Setup as root can you let me know what distro you are using so I can test it?

      -James

  9. Thank you so much for this! It worked great for me and my friend for a week (much better than my own attempt at getting a paperMC server on a RPi) but now they keep getting disconnected with “[name] disconnected: timed out”. It happens quite randomly. I have searched for the error online and i could only find that it is their issue. Is this the case or is there something wrong with my internet?

    Thanks!

    Also, how do i switch screens back to the raspbian terminal (right now, i just reconnect my ssh connection and it puts me back there).

    1. Hey Alex,

      To switch back to the Raspbian terminal press Ctrl+A and then Ctrl+D. You’ll see a message that says “[detached from 12710.pts-0.raspberrypi]” and be back at the terminal. To get back into the server after that you will just type screen -r minecraft.

      For the connection timed out message this is indeed a network problem. If it only just started happening the first thing I would try is to unplug your router for about 30 seconds and then plug it back in. If you have a separate cable modem or DSL modem do it for that one too. I’ve found consumer grade equipment does this from time to time. The problem could also be on his end so he should do the same thing to his network equipment. It may be that simple!

      If that doesn’t get it try having him run a continuous ping to the Raspberry Pi. Have him go to his command prompt and type ping -t x.x.x.x and it will continuously ping your Pi once per second. This is useful because you can see if you are getting latency spikes or timeouts there to help confirm that the entire network is dropping and not just his connection to the Minecraft server.

      Let me know what you find!

      -James

  10. Hi James,

    I installed this on my 3B+ yesterday and it’s working great so far! I just have one question: I said no to the “start server at boot” thing while setting it up, but now I’ve changed my mind. Also, I’ve already built a lot of things and don’t want to lose them. Finally, the daily reboot prompt never came up while I was installing.

    Is it possible to run the setup script again without losing any data? Or Is there a simpler option to enable both the daily reboot and the start server on startup? Thanks!

    1. Hey John,

      There absolutely is! Just run the SetupMinecraft.sh script again and it will let you reconfigure the start up service, daily reboot, etc. without touching any of the data!

      -James

      1. Hey james,

        Thanks, I did it and it worked! One more question: Would it be possible to migrate this server from the pi onto another device with more power? I just discovered an old laptop of mine that may work better. I plan to install Ubuntu Server on it and use it as a dedicated minecraft server while i tinker with my Pi on other projects.

        1. James,
          Wonderful work! Thanks for all your effort.

          I took your advice and installed Ubuntu on my Pi, replacing Raspian. However, my Pi is part of the Oreserver project, and I’d like to get the LED scripts going again. Do you know if those (python) scripts will work with Ubuntu?

          Thanks!!

  11. Hi James,

    saw some
    /home/pi/minecraft/restart.sh: 41: /home/pi/minecraft/restart.sh: StopChecks++: not found
    while testing some restart scenarios.
    Origins from the stanza
    # Wait up to 30 seconds for server to close

    in your script.

    In Raspbian Lite /bin/sh is pointing to /bin/dash what does not know ((StopChecks++)) to increment the variable.

    Replacing this by StopChecks=$((StopChecks+1)) removes the issue and should work on Ubuntu, too.

    Cheers
    Jason

  12. Hi again,

    in addition to my last post I’d like to mention that by adding

    [Service]

    TimeoutStartSec=600

    to /etc/systemd/system/minecraft.service you may overcome a timeout when wget from updating to the most recent paperclip version takes some more time. Otherwise systemctl kills the minecraft server and you may wonder why it doesn’t run after the nightly reboot.

    Cheers
    Jason

    1. Great finds Jason!

      I’ll update the service and take a look at the restart script and get those fixed!

      -James

  13. Hey James,

    I know, I know,
    1.14 just came out, but do you have any plans for a rebuild to upgrade to this?

    -Harrison

    1. Hey Harrison,

      Most definitely! Right now I’m waiting for the Paper / Spigot version of 1.14 to drop which is usually pretty quick after these new releases.

      It should appear at https://papermc.io/downloads when it is available and I will update all of the code to use it!

      -James

  14. I have an already existing server on PC, but I would like to port it to Raspberry Pi, would it be possible? (I also use CraftBukkit with a couple lag fixing plugins.)

    1. Absolutely! Since it’s the Java version there’s no portability issues between platforms. You’d just put your server.properties and world folder on the Pi.

      The plugins would be the same. You could even copy the plugins from your existing server. Paper is in the same source tree as Bukkit and Spigot so it should be very easy to do this!

    1. jamesachambers

      At the moment it does. I should probably change this though because it would be easy to make it use the world name from server.properties. I’ll add this in soon!

  15. Hello,

    I am struggling with my pie server. I have tried a few different sets of instructions and the build seams to go well, but I can not find my server from my windows Minecraft screen. I have tried the wired and the wireless IP. The only tutorial that has worked so far is if I run a Pocket Edition Server.

    Any thoughts?

  16. I saw a version of paper that was 1.14 . Are you working on a new bash file or is there an easy way for the server to update itself.

    1. Hey Dylan,

      I’ve updated the script to get 1.14.1. If you run the SetupMinecraft script again it will retrieve 1.14.1.

      -James

  17. Hi, is it possible to downgrade to 1.13.2? if so, how to downgrade? I’d like to run dynamap on my server.

    1. Sure, if you’d like to downgrade open up start.sh and replace 1.14.1 with 1.13.2 and it will change your server to that version!

  18. Hello James,
    I’m also suffering from the โ€œThere is no screen to be resumed matching minecraftโ€-problem. I had reinstalled a clean version of raspbian lite a couple of times so far with no luck.
    I followed the advice you gave Achim ealier in the year although it seems to have had no effect.
    Thank you for the work nonetheless!!

    1. So I just managed to get around this by connecting my Pi to a different network for initial setup. Although now I’m having problems with this:

      [13:27:08 WARN]: Can’t keep up! Is the server overloaded? Running 24630ms or 492 ticks behind

      The number of tickets will increase and decrease until the server crashes.
      Any ideas?

        1. Hi James,

          I’m using a Raspberry Pi 3 B+ with a clean install of Raspbian Lite (With the exception of the server itself).

          1. Can you try removing your world folder and starting fresh? I wonder if you got hit with one of the new 1.14 bugs that everyone has been talking about!

            1. I’m investigating this right now. I’m sure it’s a 1.14 issue as everyone noticed that it uses more resources to run than 1.13 did.

              So far it starts out high but then goes back down to 100 ticks behind:

              [20:59:45 WARN]: remote__ moved too quickly! 28.515927803105512,1.9755759117863079,25.361194249335057
              [21:00:32 WARN]: Can’t keep up! Is the server overloaded? Running 49957ms or 999 ticks behind
              [21:01:07 WARN]: Can’t keep up! Is the server overloaded? Running 5354ms or 107 ticks behind
              [21:02:40 WARN]: Can’t keep up! Is the server overloaded? Running 5024ms or 100 ticks behind

              1. I have made some progress. Can both of you download the latest SetupMinecraft.sh and run it to update your scripts?

                I spent several hours playing and tweaking today to find the best settings for 1.14.2 and it is running tons better.

                -James

              2. I’ve completed my investigation by both playing all day and spending a lot of time with the Paper Minecraft developers in their Discord server.
                This is actually a community-wide problem right now. Servers big and small continue to suffer horrible TPS drops, instability, long server freezes upon world save, and a multitude of other issues.
                Because of this I have returned the script to the 1.13.2 stable branch but am leaving the option to install the “development” branch if people want to try it. I’ve put a status update at the top of the post and will continue to update. I’m sure the Paper devs will fix Mojang’s mess and once they do we will move it to the stable branch!

                1. Hi Jamesachambers
                  What does this mean to us player? How do I get back to 1.13.2? Can you help me how I can get back to 1.13.2 Client and Server?
                  Thx ๐Ÿ˜€

                  1. Hey Mako,

                    Absolutely! Let’s start with the client. Open up the Minecraft launcher and go to “Launch Options”. Now click “Add New” button. Here you’ll see a dropdown where you can select which release you want to add to the launcher. Choose 1.13.2 and then save. Now when you go back to the first tab “News” you’ll see that your play button now has a dropdown arrow that lets you pick the version. That’s it for the client!

                    For the server download and run SetupMinecraft again. During the install it will ask you if you want to pick the stable (1.13.2) or development version (1.14.2). Just press enter here and it will pick the stable branch for you. Make sure you restore a backup of your 1.13.2 server before you upgraded. The server takes a backup of the whole server every time you run it and stores it in the “minecraft/backups” folder. If you just want to start a new server you can skip this step. The exact commands to restore a backup are in the article if you need to know them!

                    Let me know how it goes.

                    1. Hey James

                      It work well! I could get back to 1.13.2 but as soon I restored my worl from 1.14.2 to the old update nobody could join. I got a lot of errors and then the server restart… What am I doing wrong?

                      Thx for the amazing work and support you do!!! ๐Ÿ˜€

                    2. Hey Mako,

                      Do you have a backup from 1.13.2? It does not like downgrading afterward since the new village update adds types to the server that 1.13.2 doesn’t understand. Can you check your backups folder for backups from 1.13.2?

                    3. Hi James

                      Sadly no. We started with the Client 1.14.2. so no Worl on 1.13.2.

                      But thank you for the quick response. ๐Ÿ™‚

  19. Hi Jamesachambers
    Thank you for your guide! I love it!!!
    I just startet with the Pi experience so please go easy on me. ๐Ÿ™‚
    How can I update the server to 1.14.2?

    Thx ๐Ÿ™‚

    1. Hey Mako,

      I just updated the script to 1.14.2. Just run the SetupMinecraft script again and it will grab the latest version for you!

      -James

      1. Thank you making this so easy! Extremely simple to follow and set up. After running the 1.13.# for months and then updating to 1.14.1 a few weeks ago, I cannot get the most recent “./SetupMinecraft.sh” to update the server to 1.14.2. As done previously I ran your
        “wget https://raw.githubusercontent.com/TheRemote/RaspberryPiMinecraft/master/SetupMinecraft.sh
        “chmod +x SetupMinecraft.sh”
        “./SetupMinecraft.sh”
        series of commands but still end up with the 1.14.1 version. Any suggestions?
        I appreciate your help.

          1. Thank you! That seemed to do the trick as I did get the prompt that asked if I wanted to go with 1.3.# or 1.4.2. After reading through the comments regarding the stability and resource heavy nature of the newest release, I ended up rolling back to 1.3.# and restoring the world from the backup folder; all of which would have been difficult to impossible without your scripts, instructions, and help. Again, we thank you very much!

            1. Excellent Lee I’m glad to hear it! It’s definitely too bad that this is all happening with 1.14. The Paper developers said that they changed how chunk loading/unloading worked in the server which is a huge fundamental change. It may still take some time for it to all get ironed out since it was a lot more ambitious than just the new content they typically do in these updates!

    1. Hey Xander,

      No problem, and definitely you can add mods! Any mods compatible with Bukkit, Spigot or Paper will work.

      -James

        1. No problem Xander. It’s actually really easy. Let’s do it with an example.

          If you wanted to install the plugin WorldGuard for example located here: https://dev.bukkit.org/projects/worldguard

          Log into your Raspberry Pi and cd to minecraft/plugins/. Now download the plugin to this directory. The plugin will always be a .jar file. So to download the one I listed you would do: wget https://dev.bukkit.org/projects/worldguard/files/latest

          Now restart the server and the plugin will be installed!

  20. Hey, everything has worked great so far, but the server keeps crashing even with only 1 person on. I don’t know why, but I don’t have any plugins installed, this is just the vanilla version

    1. Hey Xander,

      If you’re trying to go back to 1.13.2 I would start fresh. Unless you already have a server with stuff built type:
      cd ~
      rm -rf minecraft

      and then run SetupMinecraft.sh again. Choose 1.13.2 and it won’t crash on you!

  21. Hey James,

    I am quite new to the linux platform and especially raspbian. How would I change details of the server, such as the difficulty or time of day?

      1. Hey Nova,

        To add yourself and others as an admin bring up the Minecraft server console with screen -r minecraft. The following command makes people a server operator (admin):

        op username

        Once you are an operator you can see all the other possible server admin commands in the /help menu. To remove a player later is: deop username

        To change the time of day: /time set noon will set the time to noon
        To change the difficulty is /difficulty easy or (normal / hard)

        -James

  22. Thank you for providing this really helpful work. I’ve got a physically attached M.2 card on my Raspi 3 Minecraft server and had problems with auto starting the service after reboot.

    It helped to alter the command “After” in /etc/systemd/system/minecraft.service as listed below:

    After=network-online.target mnt-wibble.mount

  23. Hey James! I’m running into errors when using a portal to the nether. The logs from latest.log start like this.

    [00:12:54] [Paper Watchdog Thread/ERROR]: ——————————
    [00:12:54] [Paper Watchdog Thread/ERROR]: The server has stopped responding! This is (probably) not a Paper bug.
    [00:12:54] [Paper Watchdog Thread/ERROR]: If you see a plugin in the Server thread dump below, then please report it to that author
    [00:12:54] [Paper Watchdog Thread/ERROR]: *Especially* if it looks like HTTP or MySQL operations are occurring
    [00:12:54] [Paper Watchdog Thread/ERROR]: If you see a world save or edit, then it means you did far more than your server can handle at once
    [00:12:54] [Paper Watchdog Thread/ERROR]: If this is the case, consider increasing timeout-time in spigot.yml but note that this will replace the crash with LARGE lag spikes
    [00:12:54] [Paper Watchdog Thread/ERROR]: If you are unsure or still think this is a Paper bug, please report this to https://github.com/PaperMC/Paper/issues
    [00:12:54] [Paper Watchdog Thread/ERROR]: Be sure to include ALL relevant console errors and Minecraft crash reports
    [00:12:54] [Paper Watchdog Thread/ERROR]: Paper version: git-Paper-632 (MC: 1.13.2)
    [00:12:54] [Paper Watchdog Thread/ERROR]: ——————————
    [00:12:54] [Paper Watchdog Thread/ERROR]: Server thread dump (Look for plugins here before reporting to Paper!):
    [00:12:54] [Paper Watchdog Thread/ERROR]: ——————————
    [00:12:54] [Paper Watchdog Thread/ERROR]: Current Thread: Server thread
    [00:12:54] [Paper Watchdog Thread/ERROR]: PID: 17 | Suspended: false | Native: false | State: RUNNABLE
    [00:12:54] [Paper Watchdog Thread/ERROR]: Stack:
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.DataPaletteBlock.a(DataPaletteBlock.java:180)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.Chunk.getBlockData(Chunk.java:449)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.Chunk.getType(Chunk.java:441)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.World.getType(World.java:822)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.PortalTravelAgent.findPortal(PortalTravelAgent.java:155)
    [00:12:54] [Paper Watchdog Thread/ERROR]: org.bukkit.craftbukkit.v1_13_R2.CraftTravelAgent.findPortal(CraftTravelAgent.java:45)
    [00:12:54] [Paper Watchdog Thread/ERROR]: org.bukkit.craftbukkit.v1_13_R2.CraftTravelAgent.findOrCreate(CraftTravelAgent.java:33)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.PlayerList.changeDimension(PlayerList.java:812)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.EntityPlayer.a(EntityPlayer.java:753)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.Entity.postTick(Entity.java:382)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.World.entityJoinedWorld(World.java:1562)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.World.g(World.java:1528)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.WorldServer.p_(WorldServer.java:622)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.World.tickEntities(World.java:1306)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.WorldServer.tickEntities(WorldServer.java:599)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.MinecraftServer.b(MinecraftServer.java:1107)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.DedicatedServer.b(DedicatedServer.java:439)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.MinecraftServer.a(MinecraftServer.java:940)
    [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.MinecraftServer.run(MinecraftServer.java:837)
    [00:12:54] [Paper Watchdog Thread/ERROR]: java.lang.Thread.run(Thread.java:748)
    [00:12:54] [Paper Watchdog Thread/ERROR]: ——————————

    1. Hey Seth,

      Have you ever been in the Nether before on this server? If not I would try completely resetting the Nether by closing the server and deleting the world_nether folder. Then restart the server and try taking the portal again!

      -James

      1. Hey James,

        Thanks for the reply. I stopped the server, deleted the folder, and then restarted. I tried to connect and it crashed. I think this happened because I’m probably already in the nether :/

        Thanks again!

        1. Hey Seth,

          I’ve ran across situations like this before. My usual way of fixing it is to download the server folder to a Windows PC and use a program called NBTExplorer (located at https://github.com/jaquadro/NBTExplorer ).

          This lets you edit the data files. In your situation I would place yourself back in the main world. In NBTExplorer open a folder and choose your server backup folder. Now expand the world folder and look under playerdata. Once you find your right player change the “Dimension” to 0 (which means the Overworld). Change your X Y and Z to some safe coordinates (usually just the spawn is fine) so you don’t suffocate inside the earth or fall to a horrific death when you log back in. Next click File -> Save and transfer the folder back to your server. When you log back in you should now be in the overworld again.

          Once you have logged back in you can try entering the Nether again (take a backup first just in case it starts a crash loop again).

          NBTExplorer is a very useful tool for getting rid of crashes like this. The stacktrace you pasted suggests that one of the blocks in the Nether could be corrupt:

          [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.DataPaletteBlock.a(DataPaletteBlock.java:180)
          [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.Chunk.getBlockData(Chunk.java:449)
          [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.Chunk.getType(Chunk.java:441)
          [00:12:54] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.World.getType(World.java:822)

          It’s crashing trying to get the DataPaletteBlock inside getBlockData. I’m surprised this is happening in 1.13.2 as it’s pretty stable but it’s not unheard of to see weird problems like this. Let’s first make it so you can login to the server and we’ll see if we need to go any further than that such as purging anything related to the Nether using NBTExplorer.

          -James

  24. during installation there is always a dpkg error ?

    pi@raspberrypi:~ $ ./SetupMinecraft.sh
    Minecraft Server installation script by James Chambers – June 1st 2019
    Latest version always at https://github.com/TheRemote/RaspberryPiMinecraft
    Don’t forget to set up port forwarding on your router! The default port is 2556 5
    Installing screen, sudo, net-tools, bc, wget…
    Hit:1 http://archive.raspberrypi.org/debian stretch InRelease
    Get:2 http://raspbian.raspberrypi.org/raspbian stretch InRelease [15.0 kB]
    Get:3 http://raspbian.raspberrypi.org/raspbian stretch/main armhf Packages [11.7 MB]
    Fetched 11.7 MB in 12s (966 kB/s)
    Reading package lists… Done
    Reading package lists… Done
    Building dependency tree
    Reading state information… Done
    bc is already the newest version (1.06.95-9).
    net-tools is already the newest version (1.60+git20161116.90da8a0-1).
    screen is already the newest version (4.5.0-6).
    wget is already the newest version (1.18-5+deb9u3).
    You might want to run ‘apt –fix-broken install’ to correct these.
    The following packages have unmet dependencies:
    ca-certificates-java : Depends: default-jre-headless but it is not going to be installed or
    java8-runtime-headless
    Depends: libnss3 (>= 3.12.10-2~) but it is not going to be installed
    E: Unmet dependencies. Try ‘apt –fix-broken install’ with no packages (or specify a solution).
    The current stable version of the Paper Minecraft server will be installed (1.13.2)
    The current development version is 1.14.2 but it is not stable and has serious performance issues.
    Warning: Once your server is upgraded you cannot roll it back. Please make sure you have a backup or are willing to start a new world.
    Press enter to install the stable version or if you understand the risks or type ‘dev’ to install the developer version.
    Press enter to install stable version (1.13.2) or dev to install developer version (1.14.2):
    Installation version selected: 1.13.2
    Installing latest Java OpenJDK…
    E: No packages found
    E: No packages found
    E: No packages found
    Reading package lists… Done
    Building dependency tree
    Reading state information… Done
    You might want to run ‘apt –fix-broken install’ to correct these.
    The following packages have unmet dependencies:
    ca-certificates-java : Depends: default-jre-headless but it is not going to be installed or
    java8-runtime-headless
    Depends: libnss3 (>= 3.12.10-2~) but it is not going to be installed
    libfontconfig1 : Depends: fontconfig-config (>= 2.11.0-6.7) but it is not going to be installed
    E: Unmet dependencies. Try ‘apt –fix-broken install’ with no packages (or specify a solution).
    dpkg: error: cannot access archive ‘openjdk-10*’: No such file or directory
    rm: cannot remove ‘openjdk-10*’: No such file or directory
    Reading package lists… Done
    Building dependency tree
    Reading state information… Done
    You might want to run ‘apt –fix-broken install’ to correct these.
    The following packages have unmet dependencies:
    ca-certificates-java : Depends: libnss3 (>= 3.12.10-2~) but it is not going to be installed
    openjdk-9-jre-headless : Depends: java-common (>= 0.28) but it is not going to be installed
    Depends: libcups2 but it is not going to be installed
    Depends: liblcms2-2 (>= 2.2+git20110628) but it is not going to be installed
    Depends: libnss3 (>= 2:3.17.1) but it is not going to be installed
    Depends: libxi6 but it is not going to be installed
    Depends: libxrender1 but it is not going to be installed
    Depends: libxtst6 but it is not going to be installed
    E: Unmet dependencies. Try ‘apt –fix-broken install’ with no packages (or specify a solution).
    Reading package lists… Done
    Building dependency tree
    Reading state information… Done
    You might want to run ‘apt –fix-broken install’ to correct these.
    The following packages have unmet dependencies:
    ca-certificates-java : Depends: libnss3 (>= 3.12.10-2~) but it is not going to be installed
    openjdk-9-jre-headless : Depends: java-common (>= 0.28) but it is not going to be installed
    Depends: libcups2 but it is not going to be installed
    Depends: liblcms2-2 (>= 2.2+git20110628) but it is not going to be installed
    Depends: libnss3 (>= 2:3.17.1) but it is not going to be installed
    Depends: libxi6 but it is not going to be installed
    Depends: libxrender1 but it is not going to be installed
    Depends: libxtst6 but it is not going to be installed
    E: Unmet dependencies. Try ‘apt –fix-broken install’ with no packages (or specify a solution).
    Java did not install successfully — please check the above output to see what went wrong.

    1. Hey Simon,

      Run the following command: sudo apt –fix-broken install -y

      That should clean up this dependency error. Then run sudo apt-get install openjdk-9-jre-headless -y

      Now run the installer again and you should be past all of the Java stuff!

      1. when I enter the code comes

        Command line option ‘i’ [from -fix] is not understood in comination with other options

  25. hey Jamesachambers

    when I first installed the server I could assign the server 800 memory dan I want to propagate in a few times on the latest version and because I could only give a maximum of 300 I still have somewhere to release the memory?

    1. Hey Leon,

      There’s two ways to do it. The easiest way is to run SetupMinecraft again and it will allow you to choose the memory. The other way is you can edit start.sh and on the java -jar line you’ll see Xms300M and Xmx300M which you can change to the value you want to use!

      -James

        1. Hey Leon,

          Make sure that everything is closed before you run the Setup script.

          Try running the command “top” and see what is using up all the memory on your Pi. It sounds like something is already running. If you close everything it should free the memory back up.

  26. I get this error when i try to jump into the nether for the first time :/
    if you need full log i can provide
    [20:43:33] [Paper Watchdog Thread/ERROR]: The server has stopped responding! This is (probably) not a Paper bug.
    [20:43:33] [Paper Watchdog Thread/ERROR]: If you see a plugin in the Server thread dump below, then please report it to that author
    [20:43:33] [Paper Watchdog Thread/ERROR]: *Especially* if it looks like HTTP or MySQL operations are occurring
    [20:43:33] [Paper Watchdog Thread/ERROR]: If you see a world save or edit, then it means you did far more than your server can handle at once
    [20:43:33] [Paper Watchdog Thread/ERROR]: If this is the case, consider increasing timeout-time in spigot.yml but note that this will replace the crash with LARGE lag spikes
    [20:43:33] [Paper Watchdog Thread/ERROR]: If you are unsure or still think this is a Paper bug, please report this to https://github.com/PaperMC/Paper/issues
    [20:43:33] [Paper Watchdog Thread/ERROR]: Be sure to include ALL relevant console errors and Minecraft crash reports
    [20:43:33] [Paper Watchdog Thread/ERROR]: Paper version: git-Paper-633 (MC: 1.13.2)
    [20:43:33] [Paper Watchdog Thread/ERROR]: ——————————
    [20:43:33] [Paper Watchdog Thread/ERROR]: Server thread dump (Look for plugins here before reporting to Paper!):
    [20:43:33] [Paper Watchdog Thread/ERROR]: ——————————
    [20:43:33] [Paper Watchdog Thread/ERROR]: Current Thread: Server thread
    [20:43:33] [Paper Watchdog Thread/ERROR]: PID: 18 | Suspended: false | Native: false | State: TIMED_WAITING
    [20:43:33] [Paper Watchdog Thread/ERROR]: Stack:
    [20:43:33] [Paper Watchdog Thread/ERROR]: java.lang.Object.wait(Native Method)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.PaperAsyncChunkProvider.requestChunk(PaperAsyncChunkProvider.java:211)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.PaperAsyncChunkProvider.loadOrGenerateChunk(PaperAsyncChunkProvider.java:154)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.PaperAsyncChunkProvider.getChunkAt(PaperAsyncChunkProvider.java:150)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.ChunkProviderServer.getChunkAt(ChunkProviderServer.java:111)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.PaperAsyncChunkProvider.getChunkAt(PaperAsyncChunkProvider.java:136)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.World.getChunkAt(World.java:385)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.World.getChunkAtWorldCoords(World.java:381)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.World.getType(World.java:820)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.PortalTravelAgent.findPortal(PortalTravelAgent.java:155)
    [20:43:33] [Paper Watchdog Thread/ERROR]: org.bukkit.craftbukkit.v1_13_R2.CraftTravelAgent.findPortal(CraftTravelAgent.java:45)
    [20:43:33] [Paper Watchdog Thread/ERROR]: org.bukkit.craftbukkit.v1_13_R2.CraftTravelAgent.findOrCreate(CraftTravelAgent.java:30)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.Entity.a(Entity.java:2626)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.EntityItem.a(EntityItem.java:396)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.Entity.postTick(Entity.java:382)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.World.entityJoinedWorld(World.java:1562)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.World.g(World.java:1528)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.World.tickEntities(World.java:1339)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.WorldServer.tickEntities(WorldServer.java:599)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.MinecraftServer.b(MinecraftServer.java:1107)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.DedicatedServer.b(DedicatedServer.java:439)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.MinecraftServer.a(MinecraftServer.java:940)
    [20:43:33] [Paper Watchdog Thread/ERROR]: net.minecraft.server.v1_13_R2.MinecraftServer.run(MinecraftServer.java:837)
    [20:43:33] [Paper Watchdog Thread/ERROR]: java.lang.Thread.run(Thread.java:748)

    1. You’re the second person in the past few days to say this. It sounds like there is something not working about the Nether in the current version. I’ll investigate on my own server and see if I can recreate it. The nether did used to work!

      1. managed to work around this by logging in and logging out a few times before trying to load the game, removed my plugins, set the game ticks to 300000 … ish and view distance from 8 to 6 and it seems to be fine now, but i still have to log in and log out a few times everytime the server restarts or it crashes the entire server.

  27. Hello
    I wanted to add mods to my server, that’s possible and who could you tell me roughly what to do to not destroy my server ๐Ÿ˜€
    Greetings Marc

    1. Hey Marc,

      I added a “Mods” section to the article that will tell you where you can get mods and how to install them (it’s easy!).

      -James

        1. So the only thing you want to make sure is that the mods are compatible with Bukkit or Spigot or Paper (one of the 3, they are all compatible). Some mods are for Forge which is a different server.

          This is a good place to start: https://dev.bukkit.org/bukkit-plugins

          All the mods at that link are compatible

            1. It depends on what your definition of a mod vs a plugin is. In Minecraft people usually mean “Forge” or “Sponge” when they are talking about mods which is a different type of server (Forge is actually an entire modding framework for example). These servers typically need a lot more power than a Pi will provide as they are much more resource intensive.

    1. Hey Suzy,

      If you want to load 1.12 open start.sh by going to the minecraft folder and typing: nano start.sh

      Scroll down to these lines:
      wget –spider –quiet https://papermc.io/api/v1/paper/1.13.2/latest/download
      if [ “$?” != 0 ]; then
      echo “Unable to connect to update website (internet connection may be down). Skipping update …”
      else
      wget -O paperclip.jar https://papermc.io/api/v1/paper/1.13.2/latest/download

      Change both lines to 1.12 or 1.12.2 (whichever version you are wanting to run) and then start the server!

      1. Hey Mateusz,

        To disable autostart type: sudo systemctl disable minecraft
        To change GPU memory back to default type nano /boot/config.txt and remove the line that says: “gpu_mem=16”

        -James

Leave a Comment

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

Type here..