[How to] Set up Minetestserver on raspberry Pi [RPI]

User avatar
jbb
Member
 
Posts: 77
Joined: Tue Dec 09, 2014 17:16
GitHub: JBBgameich
IRC: JBB
In-game: JBB

[How to] Set up Minetestserver on raspberry Pi [RPI]

by jbb » Sat Oct 22, 2016 15:42

This is a guide on setting up a minetest server on a raspberry pi, using the raspbian / debian OS. I don't know if somebody already made such a guide, but I wanted to share my experiences.

I tested this steps on a rasberry pi 3 with Minibian / Raspbian / debian jessie (8).

  • First thing: find an image for your raspberry Pi. I used Minibian for that. Minibian is a really minimal version of Debian / raspbian, ideal for servers. You can download minibian here: https://minibianpi.wordpress.com/download/
  • Write the image to an Sdcard. You can use win32 Disk imager in windows or
    Code: Select all
    dd if=<image.img> of=</dev/yoursdcard> bs=1M
    in linux.
    You can get the name of your Sdcard in
    Code: Select all
    fdisk -l


    Here is external help on dd: https://wiki.ubuntuusers.de/dd/
  • Now boot up your Pi after you inserted your sdcard. SSH is already preinstalled in the image, so you could continue with this steps from an other pc using PUTTY or ssh. Username / Password is root / raspberry. Now there is an optional step: You can add this lines to the /etc/apt/sources.list file to get the latest packages from debian:
    Code: Select all
    sudo nano /etc/apt/sources.list

    Add this lines and press CTL + O to save:
    Code: Select all
    deb http://ftp.de.debian.org/debian jessie main contrib non-free
    deb-src http://ftp.de.debian.org/debian jessie main non-free contrib

    Then run
    Code: Select all
    sudo apt update
    .
  • Everything should be up to date, so let's do an upgrade
    Code: Select all
    sudo apt full-upgrade

  • Now if you try installing minetest, you will get a really outdated version. The preferred way is following the instructions from here: https://wiki.debian.org/Backports
    So add this
    Code: Select all
    deb http://httpredir.debian.org/debian jessie-backports main contrib non-free
    to your souces.list, use apt update and install minetest from backports:
    Code: Select all
    apt -t jessie-backports install minetest
    .
    + Spoiler

    + Spoiler


    When install finished, you should be able to copy your minetest map to your server using filezilla.

    TIP: it's a good idea to create a seperate user for minetest, for security reasons. You can add one by "adduser minetest", and login as minetest next time.
  • Now you can start the server as described on the minetest wiki:
    Code: Select all
    nohup minetest --server --worldname <your world>

When I first tried running the minetesserver on a raspberry pi 3, I was really surprised of it's power. I tested with up to 10 players and the server still runs great.

Please say if I forgot something, or if something don't works anymore.
I hope I could help you
Last edited by jbb on Wed Dec 07, 2016 15:54, edited 1 time in total.
Minetest runs better on Linux. So I'm using Linux.
 

User avatar
captpete
Member
 
Posts: 134
Joined: Fri Nov 25, 2016 03:02

Re: [How to] Set up Minetestserver on raspberry Pi [RPI]

by captpete » Tue Dec 06, 2016 23:51

I have a question: where are the data directories (textures, mods, worlds, etc.) for MineTest in Pi?

Also you left out getting minetest-server in your apt-get which sets up the minetest.conf file in /etc/minetest, a minetestserver file in /usr/lib/minetest and a /var/games/minetest-server/.minetest/worlds/[your world] (where all the world directories should be placed under I think) .

correction: /usr/share/games/minetest/ seems to be created once minetestserver is run (minetestserver --info) and THAT contains the MineTest directory structure.
 

User avatar
jbb
Member
 
Posts: 77
Joined: Tue Dec 09, 2014 17:16
GitHub: JBBgameich
IRC: JBB
In-game: JBB

Re: [How to] Set up Minetestserver on raspberry Pi [RPI]

by jbb » Wed Dec 07, 2016 15:53

I normally create a new user for the minetest server, and run it manually using minetest --server --worldname ....
Then all worlds, mods etc. are stored in /home/minetestuser/.minetest/. You can also use minetestserver, if you need automatic start on boot. The normal raspbian image uses the default user "pi", so everything would be stored in /home/pi, on the sdcard. The minibian image I used has only the root user created, and it's often a bad Idea of letting services which are accesable from the internet running on the root account, so I use the user "minetest" for it.
Minetest runs better on Linux. So I'm using Linux.
 


Return to Servers



Who is online

Users browsing this forum: No registered users and 4 guests