Setup PaperSpigot on Ubuntu
PaperSpigot is a high performance fork of Spigot that aims to fix gameplay and mechanics inconsistencies. Paper contains numerous unique features and changes, including many performance improvements not found in Spigot. In this guide, we will setup PaperSpigot on an Ubuntu Server.
Setting up the Ubuntu Server
Section titled “Setting up the Ubuntu Server”It is recommended to run all commands as a user with sudo privileges that is
not root.
Start by ensuring that your server is up to date.
sudo apt-get update && sudo apt-get upgrade -yInstall the needed packages.
sudo apt-get install openjdk-8-jre -yCreate a swap file
Section titled “Create a swap file”Allocate the desired amount of memory. Replace 1G accordingly.
sudo fallocate -l 1G /swapfileSecure the permissions of your new swap file.
sudo chmod 600 /swapfileAllocate the swap space.
sudo mkswap /swapfileTurn on swap.
sudo swapon /swapfileMake your swap file permanent by modifying the fstab file.
sudo vim /etc/fstabAdd this line to the bottom of the file.
/swapfile none swap sw 0 0Install PaperSpigot
Section titled “Install PaperSpigot”Ensure you are in the home directory of the user you are planning to use to
install PaperSpigot.
cd ~Create a folder for PaperSpigot.
mkdir papercd paper
wget -O paperclip.jar https://ci.destroystokyo.com/job/PaperSpigot/lastSuccessfulBuild/artifact/paperclip.jarThis will download the latest build of PaperSpigot. If you would like to use a
different Minecraft version, replace lastSuccessfulBuild with a
corresponding build number which you can find
here.
Starting your server
Section titled “Starting your server”Create a start up script for your server.
vim start.shMake start.sh match the following, replacing 1024M with the amount of RAM
installed on your server.
#!/bin/sh
java -Xms512M -Xmx1024M -XX:MaxPermSize=128M -jar paperclip.jarMake start.sh executable.
chmod +x start.shStart your server.
./start.shThe first time you start your server, it will download files necessary to setup PaperSpigot. After the first run, your server will launch faster.
Optional: Run your server in the background
Section titled “Optional: Run your server in the background”Install screen.
sudo apt-get install screen -yOpen an instance of screen.
screen -S "paper"Start your server script.
cd ~/paper./start.shYou can now configure your server’s settings and install plugins.
Troubleshooting
Section titled “Troubleshooting”Accept EULA.
Section titled “Accept EULA.”If you are asked to confirm eula.txt , change eula to true.
vim eula.txtpaperclip.jar wont run?
Section titled “paperclip.jar wont run?”You need more RAM on your server or a larger swap file.
start.sh can’t run the file command on your jar file?
Section titled “start.sh can’t run the file command on your jar file?”Check to ensure everything is typed exactly the same, Linux IS case sensitive.