Set up a Barotrauma server: port, settings and joining

How to start a Torchlite Barotrauma server, join it with Direct join, why the port in serversettings.xml is rewritten on every start, and how to fix common problems.

5 min readBy Torchlite teamUpdated

Set up a Barotrauma server: port, settings and joining
On this page

A Barotrauma server on Torchlite runs the official dedicated server, installed from Steam. It starts by itself after you create it. This guide covers what happens on the first start, how players join, the one port the server uses, where the settings live, and what to check when something does not work.

What you get

Barotrauma runs on the Lite plan (1.5 GB of RAM, 1.25 CPU cores, 15 GB of disk) and on Turbo (3 GB, 1.5 cores, 20 GB). The server is small. Right after it started it used about 250 MB of RAM, and the installed files take about 0.6 GB of disk, so Lite has plenty of room.

Both plans are free. Torchlite is funded by our sponsor TorchByte and by advertising in the panel. A running server has to be renewed from the panel before its time runs out, or it stops; your files are kept. Before each start or renew, the panel shows a short sponsor break. The renewal guide explains the timer.

Your account can hold one game server, so this server uses your game slot. You can change the game later with Change game in the panel.

Create the server and start it

  1. Open Create your server, choose a plan, then Barotrauma.
  2. Confirm your email with the code we send.
  3. Wait while the server is built. It downloads Barotrauma from Steam without a Steam account, and then starts.
  4. Log in at game.torchlite.host with the same email and password.
  5. Open your server and go to the Console.

The first start can take a while, because the files are downloaded first. When the console prints Server started, the server is up and listening. If you stop it and start it again later, you will see the same line once the server is ready.

If the server has an update waiting, the Auto Update setting on Startup decides whether it is installed when the server starts. It is on by default. Keep it on unless you have a reason to stay on an older version, because the game and the server must match.

Join with Direct join

The server is not something you find by searching. Your players join it by address.

  1. Open the Console or the Network page in the panel and find the address and port. It looks like barotrauma.play.torchlite.host:12400. The name part and the port are specific to your server, so always use the ones the panel shows.
  2. In Barotrauma, open the server list screen and choose Direct join.
  3. Type the address and port, exactly as shown in the panel, and confirm.

Everyone who joins needs Barotrauma on Steam, on the same version as the server. Send the address to your crew in a message. If you set a password in the settings file, they enter it when asked.

The server uses UDP. You do not have to open or forward anything: the port is already open on our side, and traffic goes through zero.ms DDoS protection in Bucharest.

The one port

A Barotrauma server uses a single UDP port, the one Torchlite assigns to your server. It cannot be changed. You will not see a second port for queries on the Network page, because this setup does not use one.

Barotrauma reads its port from serversettings.xml and ignores the command line, so we handle it ourselves. Every time the server starts, our start script writes the assigned port into the port entry of serversettings.xml. That means:

  • If you type a different port into the file, it is replaced at the next start.
  • You never have to set the port yourself.
  • The port entry must stay in the file, because that is where the script writes it.

When the server is installed, Torchlite creates a small serversettings.xml for you if there is none. It holds a default server name, Torchlite Barotrauma server, the assigned port, and enableupnp="false". Leave enableupnp off: there is no router for it to talk to.

Edit the server settings

Everything except the port is in serversettings.xml, which sits in the main folder in Files.

  1. Stop the server. The game can rewrite the file while it runs, so edits made while it is running may be lost.
  2. Open Files, click serversettings.xml and edit it. You can also download it, edit it on your computer and upload it again over SFTP.
  3. Save the file and Start the server.

The name entry is the server name. After the server has started once, Barotrauma fills the file with more settings, such as the password and the maximum number of players. Change one value at a time, so you can undo it if the server does not start. Take a copy of the file before you begin. The backups guide shows how to save the whole server.

If the server does not start after an edit, the console shows an error about the file. Put your copy back and try again.

Updates

With Auto Update on, the server checks Steam each time it starts and installs a new version if there is one. When Barotrauma updates, restart your server once and the versions match again. If players still get a version error, ask them to let Steam finish updating their game.

Common problems

Players cannot connect

Check these in order:

  1. The console printed Server started.
  2. The player typed the address and port from the panel, not an address from somewhere else.
  3. The player used Direct join, not the server list search.
  4. The server is still running and was not stopped for lack of renewal.

The port I typed in serversettings.xml is gone

This is expected. Our start script writes the assigned port into the file on every start. The port cannot be changed, so there is nothing to set.

Players get a version error

The game and the server are on different versions. Make sure Auto Update on Startup is 1, restart the server, and have players update Barotrauma on Steam.

The server does not start after I edited the settings file

A bad value or a broken tag in serversettings.xml can stop the start. Read the last lines of the Console, restore your copy of the file and try again.

The server stopped by itself

Free servers need renewing while they run. Keep the panel open and press Renew when it asks, then press Start if it already stopped. Nothing is deleted when it stops. A server with nothing done on it for 5 days is deleted, with an email one day before.

Stuck on a step?

Ask on the forum. Your question links back to this guide, so whoever answers knows where you are.

Ask about this guide

About the author

Torchlite team

The people who run Torchlite

We build and run the Torchlite panel and the nodes. Every guide is checked on our own servers before it goes up, and updated when the panel changes.

Found a mistake? Tell us on Discord

Related guides

All guides →