Gaming Servers

Barotrauma

Host a Barotrauma dedicated server on Linux or Windows

Platform Support

PlatformSupportNotes
Linux✅ Native
Windows✅ Native

Hardware Requirements

Resource Requirements

  • RAM: 2GB minimum, scales with player count
  • CPU: 2+ vCPU
  • Storage: 3GB for game files
  • Network: 50-100 Mbps recommended for 16+ players

Linux Installation

1. Install via SteamCMD

mkdir -p /opt/barotrauma
cd /opt/barotrauma

# Download SteamCMD
curl -sqL "https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz" | tar xvz

# Install Barotrauma dedicated server (AppID 1026860)
./steamcmd.sh +force_install_dir /opt/barotrauma +login anonymous +app_update 1026860 validate +quit

2. Server Configuration

Create /opt/barotrauma/serversettings.xml:

<?xml version="1.0" encoding="utf-8"?>
<ServerSettings>
  <ServerName>DeluxHost Barotrauma Server</ServerName>
  <ServerMessageCharLimit>1000</ServerMessageCharLimit>
  <MaxPlayers>16</MaxPlayers>
  <IsPublic>true</IsPublic>
  <Port>27015</Port>
  <QueryPort>27016</QueryPort>
  <Password></Password>

  <GameMode>Campaign</GameMode>
  <Submarine>
    <Name>Dugong</Name>
    <Path>Content/Submarines/Dugong.sub</Path>
  </Submarine>

  <Campaign>
    <EnableCampaignMode>true</EnableCampaignMode>
    <SavePath>Data/SavedCampaigns/</SavePath>
  </Campaign>

  <Network>
    <AutoRestart>true</AutoRestart>
    <AutoRestartInterval>300</AutoRestartInterval>
    <KickAFKTime>600</KickAFKTime>
    <BanResetInterval>3600</BanResetInterval>
  </Network>

  <Gameplay>
    <Difficulty>1.0</Difficulty>
    <StartWhenClientsReady>true</StartWhenClientsReady>
    <StartDelaySeconds>30</StartDelaySeconds>
    <AllowSpectating>true</AllowSpectating>
    <AllowRagdollButton>true</AllowRagdollButton>
    <AllowEndVoting>true</AllowEndVoting>
  </Gameplay>

  <ContentPackages>
    <Package name="Data/Submarines/Dugong.sub" />
    <Package name="Data/Outposts/Outposts.xml" />
  </ContentPackages>
</ServerSettings>

3. Campaign Configuration

Create /opt/barotrauma/config_player.xml:

<?xml version="1.0" encoding="utf-8"?>
<campaignSettings>
  <MoneyDistribution>
    <Boss>30</Boss>
    <Captain>20</Captain>
    <Engineer>20</Engineer>
    <Medic>15</Medic>
    <Security>15</Security>
  </MoneyDistribution>

  <Difficulty>
    <EnemyHealthMultiplier>1.0</EnemyHealthMultiplier>
    <ProjectileDamageMultiplier>1.0</ProjectileDamageMultiplier>
    <CostMultiplier>1.0</CostMultiplier>
    <MissionRewardMultiplier>1.0</MissionRewardMultiplier>
  </Difficulty>

  <WreckThreshold>70</WreckThreshold>
  <HullRepairAmount>100</HullRepairAmount>
</campaignSettings>

4. Launch Script

Create /opt/barotrauma/start_server.sh:

#!/bin/bash
cd /opt/barotrauma

# Run dedicated server
./DedicatedServer \
  -servername "DeluxHost Barotrauma" \
  -port 27015 \
  -queryport 27016 \
  -log

Make executable:

chmod +x /opt/barotrauma/start_server.sh

5. Systemd Service

Create /etc/systemd/system/barotrauma.service:

[Unit]
Description=Barotrauma Dedicated Server
After=network.target

[Service]
Type=simple
User=barotrauma
WorkingDirectory=/opt/barotrauma
ExecStart=/opt/barotrauma/start_server.sh
Restart=on-failure
RestartSec=10
StandardOutput=journal

[Install]
WantedBy=multi-user.target

Enable and start:

sudo systemctl daemon-reload
sudo systemctl enable barotrauma
sudo systemctl start barotrauma

6. Firewall Configuration

# Allow Barotrauma ports
sudo ufw allow 27015/udp
sudo ufw allow 27016/udp

Windows Server Setup

1. Install via SteamCMD

mkdir C:\Games\Barotrauma
cd C:\Games\Barotrauma

REM Download and extract SteamCMD
powershell -Command "Invoke-WebRequest https://steamcdn-a.akamaihd.net/client/installer/steamcmd_windows.zip -OutFile steamcmd.zip; Expand-Archive steamcmd.zip -DestinationPath ."

REM Install Barotrauma dedicated server
steamcmd.exe +force_install_dir C:\Games\Barotrauma +login anonymous +app_update 1026860 validate +quit

2. Server Configuration

Place serversettings.xml and config_player.xml in C:\Games\Barotrauma\ with the same content as Linux version.

3. Run as Windows Service (NSSM)

REM Download NSSM
nssm install BarotraumaServer "C:\Games\Barotrauma\DedicatedServer.exe" "-servername 'DeluxHost Barotrauma' -port 27015 -queryport 27016"
nssm set BarotraumaServer AppDirectory "C:\Games\Barotrauma"
nssm start BarotraumaServer

Tips & Tweaks

Admin Commands (In-Game Console)

Press ~ to open console in multiplayer sessions:

CommandDescription
kick <player>Kick a player
ban <steamid>Ban by Steam ID
unban <steamid>Unban player
mute <player>Mute player voice
unmute <player>Unmute player
restartRestart mission
disablesavingDisable save file saving

Campaign Save Location

Save files are stored in:

  • Linux: ~/.local/share/Barotrauma/SavedCampaigns/
  • Windows: %APPDATA%\Barotrauma\SavedCampaigns\

Submarine Selection

Popular submarines:

  • Dugong: Medium-sized, balanced
  • Typhon: Large, well-armored
  • Humpback: Small, maneuverable
  • Orca: Military-grade
  • Catfish: Stealth-focused

Configure in serversettings.xml:

<Submarine>
  <Name>Typhon</Name>
  <Path>Content/Submarines/Typhon.sub</Path>
</Submarine>

Difficulty Settings

Adjust difficulty multipliers in config_player.xml:

MultiplierLowNormalHardExtreme
EnemyHealth0.51.01.52.0
ProjectileDamage0.51.01.52.0
Cost0.81.01.21.5
MissionReward1.51.00.70.5

Workshop Mods/Submarines

Enable custom submarines via Workshop:

<ContentPackages>
  <Package name="Data/Submarines/Dugong.sub" />
  <Package name="[WORKSHOP_ID]" />
</ContentPackages>

Download workshop mods and add their IDs to the config.

Performance Optimization

SettingImpactNotes
MaxPlayersHighestEach player ~2-3MB RAM
DifficultyMediumHigher difficulty increases CPU
EnableCampaignModeMediumCampaign uses more resources than missions
AutoRestartLowPeriodic restarts prevent memory leaks

Server Rotation

Create mission rotation in serversettings.xml:

<GameMode>MissionRotation</GameMode>
<MissionRotation>
  <Mission name="Salvage" />
  <Mission name="Bounty Hunt" />
  <Mission name="Rescue" />
  <Mission name="Monster Hunt" />
</MissionRotation>

Monitoring Server Health

# Monitor RAM usage
free -h

# Check process
ps aux | grep DedicatedServer

# View logs
tail -f /opt/barotrauma/log.txt

Common Issues

  • High RAM Usage: Reduce MaxPlayers or enable periodic restarts
  • Mission Failures: Verify Difficulty is not too high
  • Submarine Won't Load: Check submarine path in serversettings.xml
  • Player Disconnects: Increase KickAFKTime if needed
  • Campaign Save Corruption: Keep multiple backup saves using autosave_slots

Useful Tips

  • Money Management: Adjust MoneyDistribution percentages per role
  • Hull Integrity: Higher HullRepairAmount makes repairs easier
  • Wreck Threshold: Set wreck to 70% damage for challenging gameplay
  • Anti-Grief: Use AllowRagdollButton=false to prevent physics abuse

On this page