TMF Dedicated Server init.d Scripts
On Unix/Linux starting and stopping applications is commonly done via init.d scripts (on System V-derived distributions) and less commonly via rc* scripts (on BSD-derivatives). Variants such as the custom init system on Gentoo and new developments like initng and upstart also exist. See Wikipedia for more information on init.
This page aims to collect proven and tested init.d scripts for the TMF dedicated server on a variety of distros. You are encouraged to submit scripts for distros not listed here, as well as other useful start/stop scripts. The dedicated server is required by XASECO, and scripts for that can also be found on this site.
For more discussion of Linux start-up scripts, see for example this thread and this one. For a web interface to starting/stopping TM-related processes, try the Nouse Web Tool Bundle.
The entire TrackMania Forever server system is assumed to be installed in /home/tmf/, with the dedicated in /home/tmf/TMF/ and XASECO in /home/tmf/xaseco/. The user is named tmf and the group is tm, allowing for multiple TM users within this same group. You are of course free to deviate from this but will then have to adapt the scripts yourself.
Processes are started under the aforementioned user, and can be accessed (e.g. to check their status) by process name or ID. It is therefore recommended (and for some scripts mandatory) that the process name is unique when running multiple dedicated servers and XASECOs.
Process IDs can be stored in /var/run/*.pid files, and process locks in /var/lock/ or /var/lock/subsys/ can help prevent running the same process more than once, but not all distros deploy both mechanisms.
When scripts invoke the standard RunTrackmaniaForever.sh script that launches the dedicated server, that is expected to look similar to this:/home/tmf/TMF/RunTrackmaniaForever.sh :The init.d script itself is expected to be named /etc/init.d/tmfd.#!/bin/sh cd /home/tmf/TMF ./TrackmaniaServer /game_settings=MatchSettings/stadium_all.txt /dedicated_cfg=dedicated_cfg.txt
Last updated: 2011-10-16