Setting up a server- Ububtu

From Minetest Wiki
Jump to: navigation, search

If using a VPS. pleas download the following additional tools:

  • hxxp://www.chiark.greenend.org.uk/~sgtatham/putty/-- SSH client for Windows (Mac/Linux don't need this)
  • hxxp://cyberduck.ch/-- Mac/Win SFTP client
  • hxxp://filezilla-project.org/-- Alternative SFTP client
These instructions are written for the root user; if not root, you may use the root shell with
sudo su -
or run the server as your user by prefixing all commands with
sudo

1. forward the port on your router to your computer

2.
apt-get install python-software-properties; add-apt-repository ppa:minetestdevs/stable; apt-get update; apt-get install minetestc55; nohup minetest --server &

Your minetest world, config, mod and such are in ~/.minetest

You server is up, you can stop here, or continue to creat daily backups

(if not root, replace /root with /home/username)

3.
mkdir -p ~/minetest/backups; apt-get install xz-utils; nano /etc/cron.daily/backup

4. Enter

#!/bin/sh
####################################

#stop server
killall minetest

# What to backup. 
backup_files="/root/.minetest/worlds"

# Where to backup to.
dest="/root/.minetest/backups/"

# Create archive filename.
archive_file="worlds_$(date +%y%m%d).tar.xz"

# Backup the files using tar.
tar cJf $dest/$archive_file $backup_files

#restart server
nohup minetest --server &
5.
chmod 755 /etc/cron.daily/backup
Personal tools
Namespaces
Variants
Actions
Navigation
Resources
Toolbox