Database Backups
Scheduled backups of your game database, how to download and restore them.
The media service backs up your game database (the one in mysql_connection_string) to tgiann-media/backups/backup-<date>.sql.gz inside the script folder. Each backup is one consistent snapshot taken while the server runs, players stay online. It restores exactly, float coordinates included.
Turn them on
Backups are off until you turn them on on the Backups page:
Back up automatically
Off
Every
4 hours
1 to 168 hours
Keep
28 backups
1 to 500, older ones are deleted
The first automatic backup is checked 5 minutes after the server starts. Back up now on the same page takes one at once.
Download
Click the download button next to a backup on the Backups page. The file comes from the media port of your server, so that port must be open, see Ports and Firewall. A download link works for 10 minutes and only once.
Restore
Stop the server first and restore into an empty database (or one you are ready to overwrite).
Linux:
gunzip -c backup-2026-10-24_04-00-00.sql.gz | mysql -u root -p your_databaseWindows: extract the .sql file with 7-Zip, then run it in HeidiSQL (File > Run SQL file) or:
What is not in a backup
The tgiann-media folder (statistics, logs, screenshots, videos). Copy that folder to keep them, see Media Service.
Backups live inside the script folder too: keep tgiann-media/ when you update the script, see Updating from an Older Version.
On Linux the backups folder and files are readable by the server's user only.