Server

**This page is a page in need of work. It might be outdated, or contain misinformation.**

The **server** software is used to host multiplayer games.

## Command Line Options

These are the arguments passed to the server via the command line.

* **--help**: show help message
* **--port arg**: listening port of the server *Default: 27000*
* **--max-players arg**: maximum number of online players *Default: 10*
* **--save-interval arg**: timestep between savings *Default: 300*
* **--server-name arg**: server name, will be displayed when queried - added in 0.10.1
* **--galaxy-name arg**: galaxy name, appended to datapath, final path will be [datapath]/[galaxyname] - added in 0.10.1
* **--datapath arg**: folder the galaxies will be stored in, will be prepended to galaxy name
* **--admin arg**: steam id(s) of the administrator(s) of the server
* **--seed arg**: seed of the server
* **--difficulty arg**: difficulty of the server, allowed values are: -3, -2, -1, 0, 1, 2, 3 *Default: 0*
* **--infinite-resources arg**: enable infinite resources for all players
* **--collision-damage arg**: amount of damage done to an object on collision, from 0 to 1. 0: no damage, 1: full damage. default: 1
* **--same-start-sector arg**: indicate if all players should start in the same sector
* **--threads arg**: specify the number of threads used to update the sectors
* **-t [ --trace ] arg**: tracing options. Can be more than one. Allowed values are: network scripting threading io database input error warning exception user game system debug sound gl all
* **--exit-on-last-admin-logout**: shut down when last administrator logs out
* **--stderr-to-log**: redirect std error output from console to log file
* **--stdout-to-log**: redirect std console output from console to log file
* **--public arg**: indicate if the server should allow other players to join
* **--listed arg**: indicate if the server should show up on public server lists
* **--use-steam-networking arg**: use steam networking and authentication for users

## Server Configuration Options

These are the server options which can be found in the server.ini file located in the folder of your galaxy either at "AppData\Roaming\Avorion\galaxies\<galaxy name>" or ".avorion/galaxies/<galaxy name>" on Linux systems.

Some server options are reverted back to their default value depending on the scenario value in server.ini. One example is UnlimitedShipSize - if scenario isn't set to "3" it will revert back to "false" every time it's loaded.

## Setting up your own server

A guide to setting up your own server can be found here Setting up a server.

## Remote controlling the server via RCON

If the RCON interface is enabled (meaning: an RCON password is set), the server can be remote controlled via RCON.

The following RCON clients are known to work:

* http://rcon.io/
* http://facepunch.github.io/webrcon/
* https://github.com/n0la/rcon [for command line, requires a little programming knowledge]

If not changed via config file or command line arguments, the default RCON port for Avorion is 27015.

## Server log

The server creates a logfile that is located in %appdata%\Avorion\serverlog.txt.

## Known issues

The server software only supports ASCII characters. The server can thus only operate on paths that contain ASCII characters. This includes the log file.

When making edits to this file double check to make sure everything is correct. If there is a single mistake the game will remake the entire file with default settings with a new seed. This can lead to some save corruption, Make backups before editing.