DocsHostingRunning

Running and updating

The first start

No download holds game code, so a server makes the engine's code itself the first time it starts, from halo3/halo3.dll in its game folder, and keeps it in its caches. It does this once per release, with no window, and says so in data/<server>/server.log:

server.log
[translate] the code is not in the cache: translating on 4 threads
[translate] done in 12.4 s

That takes about 5 seconds on four fast cores, 10 to 20 on an ordinary four-core machine, and longer on one or two. The caches are in the Cache folder of the account's player folder (%LOCALAPPDATA%\ProjectReclaimer, ~/.local/share/ProjectReclaimer or ~/Library/Application Support/ProjectReclaimer), RECLAIMER_CACHE_DIR moves them, and in Docker they're in the cache volume. They rebuild if you delete them. The first start on a machine also moves an old Documents\My Games\Project Reclaimer folder to the new player folder; server folders stay where they are.

The dedicated command

Run these in the server folder, or name the file with --config FILE (--server FILE in place of dedicated takes the same commands).

dedicated [--verbose], dedicated run
Runs every enabled server and this machine's master. --verbose prints every line of each server's log.
init [DIR] [--from [MCC]] [--maps A,B]
Writes a commented dedicated.toml and playlists/slayer.playlist.json, keeping a folder that already has one. --from copies the game files from MCC's folder into game/, hard-linked on the same drive, and --maps names the maps to copy; it also takes campaign, odst, reach, reach-campaign, halo1, halo1-campaign, halo2 and halo2-campaign for whole games. Run again on the same folder, it adds what's missing.
check
Installs missing Workshop items, then checks the configuration, the game folder, each server's games and rules, RCON, the master and the ports, says which mission a campaign names, and notes the objects a server's games would miss. It exits with an error when something is wrong.
status
Whether the master answers and how many servers it lists, and each server's address, game, state and players. It exits with an error when one is down.
content [WORDS]
The maps and game types map, game and playlists name, and every campaign and mission campaign names.
mods
Installs missing Workshop items, then lists the references playlists and map take for installed mod maps.
playlist [list], playlist show FILE, playlist new NAME --maps A,B --games X,Y [--vote-seconds N] [--replace]
Every playlist and who plays it; one playlist's games, their share and options; a playlist of every map with every game type.
bans, ban TARGET [--reason R] [--for TIME], unban TARGET
The shared ban list. See admins, kicks and bans.
vpn, vpn check IP, vpn allow TARGET [NOTE], vpn revoke TARGET, vpn update
The VPN block: its lists and allowances, whether an address is refused, an allowance and its revocation, and fetching the lists now. See VPN blocking.
reload
Asks the running dedicated to apply the edited configuration, and prints its report. See changing settings while servers run.
rcon [--server NAME] [--json] [--watch] [COMMAND]
The remote console from this machine. See RCON.
stats-key
The key this configuration's servers sign their stats reports with. See stats.

Everyday running

  • dedicated prints joins, leaves, kicks, bans, refused players and errors with each server's name; --verbose prints everything. Every line also goes to data/<server>/server.log. The run before is kept as server.previous.log, and once a log passes 20 MB, it starts afresh and keeps the full ones as server.log.old, .old.2 and .old.3: four files at most however long it runs (RECLAIMER_SERVER_LOG_MB and RECLAIMER_SERVER_LOG_KEEP change the size and count). A line repeated many times a second is counted instead of written again. This machine's master logs to data/master/master.log.
  • dedicated status shows whether this machine's master answers and how many servers it lists (Master · TCP 49175 · lists 2 server(s)), then each server's address, game, state and players, such as Big Team Battle · 203.0.113.4:49176 · Slayer on Guardian · playing · 3/16 players, with each player's name, player ID and address. Split-screen players count too, and are named under the player whose PC they play on. It exits with an error while a server is down or the master doesn't answer, so monitoring and health checks can use it. See also live status for panels.
  • A server that stops is started again after 1 second, then after longer waits if it keeps stopping, up to a minute, and at once if it had run for 10 minutes. The notice says why it stopped, such as "Big Team Battle" stopped after 29 s (it crashed (signal 11 …); if this keeps happening, send its log with a bug report): starting again in 1 s. See data/big-team-battle/server.log. It restarts with the game it was playing.
  • A server that stops saying it's alive for 90 seconds is stopped and started again. One that waits for long work that still goes on, such as the Forge library's first build, keeps saying so and isn't.
  • Before it ends a frozen server, dedicated keeps what it was doing: hang-time.txt beside the log, with its last status and, on Linux, what each of its threads was waiting on, and server.hung-time.log, its log up to then. The newest three of each stay. The server's own log also says where its main loop is stuck once it hasn't turned for 30 seconds. Send these with a bug report.
  • A server started again after a crash or a freeze goes on where its playlist was, and counts its games on.
  • An idle server writes little: its log repeats no status line that hasn't changed, and players' playtime is saved at each game's end and every 15 minutes.
  • A server starts again by itself when its game session is lost, so it never stays listed while nobody can join:
    • When the session ended, the server restarts at once. The notice says its game session ended and dropped every player.
    • When four or more players leave at once, the server only watches, and says so in its log. It restarts only when a player who has connected since is left waiting: their game asks to join and the session hasn't taken them within 12 seconds. It never restarts while it's simply empty.
  • A server sends the game's packets from a thread of its own, so the game's own thread doesn't wait on the network.
  • Empty servers wait in their lobby using very little processor, and start a game when someone joins, or once min_players players are in. A game every player left ends after 5 seconds.
  • A game that comes to nothing sends the server back to its lobby, with its players kept, and the log says the session did not begin the game or the session left the game with no results. A session lost for a minute starts the server again.
  • A server never stays stuck between games. A player's game that stops answering for 30 seconds while the next map is made no longer holds the others up (it stays connected, and joins when its map is ready). A server whose own making of the next map gets nowhere for 30 seconds, or whose starts keep failing, starts again by itself, and its players' games join it again.
  • A map that fails to load no longer brings a server down. The server tells its players in chat, asks their games to join again, and tries the same game again, up to three times in a row; then it skips that game for 30 minutes and plays the next. A game whose content can't be made here, or that needs more memory than one map has, is skipped until the server program restarts. A skipped game is never drawn or offered on a ballot, by the server or its failover standby. Editing that game's playlist entry clears its skip on the next reload; a game the console picked outside the playlist is never retried or skipped.
  • After each game, back in its lobby, a server logs its own memory: [server] back in the lobby: memory 2,412 MiB (+38 this game, +310 since start; the engine's heap 1,204 MiB). The same figures are in status.json's memory and the console's status. Quote these lines when you report a server that grows from game to game.
  • A game or round that ends for a reason the screen doesn't show, such as a team emptied, says why in the log and in chat; see game endings in chat.
  • A server that can't keep up while players are on logs Server falling behind once a minute, and every 5 minutes it logs its upload; see servers per machine.
  • Since 0.10.12, a seat a player can't take says why in the log ([seats] slot 7 (team 1) cannot take the driver seat (1) of …: the vehicle use trait is None), and a team game then counts its vehicles on each half of the map in a [census] line: alive, crewed, made since the last count, and wrecks. It is written at most once a minute, or when one half has had no free vehicle for a minute, so when a team says it can't get a vehicle the log shows whether its side had any left.
  • Ctrl+C, SIGINT and SIGTERM stop every server and the master, and close any forwarded ports. On Windows, closing the console does too.
  • A server the console's quit stopped stays off until dedicated restarts.

To update Project Reclaimer, stop the servers, replace the program with the new download (on Windows, project-reclaimer-dedicated-v0.10.12.exe renamed the same way; on Linux, the new tarball unpacked over the old one; on macOS, the new zip's files over the old ones, or the new app) and start them again, or turn on automatic updates. In Docker, docker compose pull && docker compose up -d. The first start of a new version prepares the engine again. Players can only join servers on their own version, so update your servers when a release comes out; see one version for everyone. Coming from 0.9? See updating a 0.9 server.

After a game update on Steam, nothing needs doing. The game keeps a copy of the engine files it was built for, in each server's own folder, and carries on from it when the game's own file changes or is gone. Only a server that has never started on the old file can't: a new server folder made after an update needs a Project Reclaimer release for the new file, and the log says which build it found and which it needs.

One version for everyone

Every machine in a game needs the same version of Project Reclaimer. A server admits only players on exactly its own version:

  • The Server Browser's Version column shows the version each server runs, in red when it isn't the player's own. Such a server is marked OTHER VERSION and can't be joined, and its card says which side needs to update.
  • A refused join, by Direct Connect too, names both versions and the side that needs to update.
  • Once a release is out, players who update can't join a server still on the previous one. Update your servers with each release, by hand or with automatic updates, every server that shares your ban list included, and tell your players to update too.
  • 0.9 and 0.10 can't play together at all: the network protocol is new, so servers, players and masters move together.

Automatic updates

Servers can update Project Reclaimer by themselves. It's off until you turn it on, at the top of dedicated.toml (before any [section]), or with RECLAIMER_DEDICATED_AUTO_UPDATE=true. Start the servers again once to start it.

dedicated.toml
auto_update = true
  • The servers check for a new stable release when they start and every hour after. Pre-releases are never installed.
  • A new release downloads while the games go on, and is checked against the release's SHA-256 checksum before it replaces the program. Then every server stops and starts again on the new version, with the same settings. Games under way end, and players have to join again.
  • It installs the release's server package under the program's own file name. On Windows that's project-reclaimer-dedicated-version.exe, so a copy of the game client becomes a server-only build: play from another copy. On Linux it's project-reclaimer-dedicated-version-linux-arch.tar.gz, replacing the program and the package's files beside it. On macOS it's project-reclaimer-dedicated-version-macos-aarch64.zip the same way, or the whole app for a server run from the app.
  • The program's folder must be writable by the account the servers run as. Run one dedicated per copy of the program, so two never update the same file.
  • A failed check or download leaves the servers running and tries again an hour later; the console says why.
  • It updates Project Reclaimer only, and only a release build: [update] auto_update is on, but this build has no release feed means this one isn't. It doesn't apply in Docker, where the image is the update (see Docker).
  • Settings, bans, playlists, content and game files stay as they are. Set auto_update = false and restart to stop updating; the version installed stays.