FreeBSD Manual Pages
FREECIV21-SERVER(6) Freeciv21 Manual FREECIV21-SERVER(6) NAME freeciv21-server - The server for the Freeciv21 game. SYNOPSIS freeciv21-server [ -f|--file <FILE> ] [ -l|--log <FILE> ] [ -p|--port <PORT> ] [ -r|--read <FILE> ] [ -s|--saves <DIR> ] [ --ruleset <RULE- SET> ] [ -a|--auth ] [ -D|--Database <FILE> ] [ -G|--Guests ] [ -N|--Newusers ] [ -h|--help ] [ -v|--version ] DESCRIPTION Freeciv21 is a free open source turn-based empire-building 4x strategy game, in which each player becomes the leader of a civilization. You compete against several opponents to build cities and use them to sup- port a military and an economy. Players strive to complete an empire that survives all encounters with its neighbors to emerge victorious. Play begins at the dawn of history in 4,000 BCE. Freeciv21 takes its roots in the well-known FOSS game Freeciv and ex- tends it for more fun, with a revived focus on competitive multiplayer environments. Players can choose from over 500 nations and can play against the computer or other people in an active online community. The code is maintained by the team over at Longturn.net and is based on the QT framework. The game supports both hex and square tiles and is easily modified to create custom rules. An HTML version of this manual page along with much more information is available on our documentation website at https://longturn.readthedocs.io/. This is the server program used to establish a Freeciv21 server. For more information on the game, refer to freeciv21-client(6). This manual page only lists the command line arguments for the server program. For details of the directives a server administrator can use to control aspects of the server, see freeciv21-game-manual(6). OPTIONS The following options are accepted on the command line of the server. They may not be combined as with other tools. For example: freeciv21-server -fp savegame.sav 5556 will not work. Instead you will need to enter each option separately, such as, freevic21-server -s savegame.sav -p 5556. TIP: It is generally considered a best practice to write a .sh script to run your server. This way you do not have to remember all the com- mand line options to use every time you run your server. -A, --Announce <PROTO> Announce game in LAN using protocol PROTO (IPv4/IPv6/none). De- fault is IPv4. Options include: IPv4, IPv6, or none. -B, --Bind-meta <ADDR> Connect to metaserver from this address. Default will be your public IP address assigned from your internet service provider. NOTE: With regard to the command line arguments concerning the metaserver, Freeciv21 does not have its own metaserver at this time and the legacy Freeciv metaserver does not support Freeciv21. This means, right now, that all commands related to the metaserver are held over from the fork from legacy Freeciv until the Longturn community cre- ates a custom metaserver. -b, --bind <ADDR> Listen for clients on ADDR. Default is the IP address of the server computer. -d, --debug <LEVEL> Set debug log level (fatal/critical/warning/info/debug). Default log level is info. -e, --exit-on-end When a game ends, exit instead of restarting. -F, --Fatal Raise a signal on failed assertion. An assertion is a code cal- culation error. With this set, the server process will SEGFAULT instead of issuing a warning message to the terminal console. -f, --file <FILE> Load saved game FILE. Useful when wanting to restart a game. -i, --identity <ADDR> Be known as ADDR at metaserver or LAN client. -k, --keep Keep updating game information on metaserver even after failure. Default is not to keep updating. -l, --log <FILE> Use FILE as logfile. Generally a very good idea when running a server. -M, --Metaserver <ADDR> Set ADDR as metaserver address. Allows you to point to a spe- cific metaserver instead of the default: https://meta.freeciv.org/ -m, --meta Notify metaserver and send server's info. -p, --port <PORT> Listen for clients on port PORT. Default is 5556 as assigned by IANA -q, --quitidle <TIME> Quit if no players for TIME seconds. -R, --Ranklog <FILE> Use FILE as ranking logfile. Generally a very good idea when running a server. -r, --read <FILE> Read startup file FILE. -S, --Serverid <ID> Sets the server id to ID. -s, --saves <DIR> Save games to directory DIR. Generally a very good idea to save games at least every turn and depending on how long the turns are set to, to save within a turn. In the case of a server crash, restarting from a save comes in very handy. -t, --timetrack Prints stats about elapsed time on misc tasks. Typically used to test code performance. -w, --warnings Warn about deprecated modpack constructs. --ruleset <RULESET> Load ruleset RULESET. Default is the Civ2Civ3 ruleset. --scenarios <DIR> Save scenarios to directory DIR. -a, --auth Enable database authentication (requires --Database). -D, --Database <FILE> Enable database connection with configuration from FILE. -G, --Guests Allow guests to login if auth is enabled. See -N, --Newusers Allow new users to login if auth is enabled. -h, --help Display help on command line options and quits. --help-all Display help including Qt specific options and quits. -v, --version Display version information and quits. EXAMPLES Here are some examples: freeciv21-server --file oldgame.sav -p 2224 Starts a server on port 2224, loading the savegame named oldgame.sav. freeciv21-server -R ranklog -l logfile -r start-script -f oldgame.sav.xz -p 2224 Starts a server on port 2224, loading the savegame named oldgame.sav.xz. Player ranking events are logged to ranklog, other logging events are placed in logfile. When the server first starts, it immediately executes the server settings script named start-script. See freeciv21-server-manual(6) for more in- formation on the server settings script. freeciv21-server -a -D users.conf -G -N -q 60 -l logfile -s ./saves -p 2224 Starts a server on port 2224 with authentication enabled (-a, -D, -G, and -N). If no activity for 60 seconds the server will quit (-q). Logging events are placed in logfile and periodic saves are placed in the ./saves directory. FILES The freeciv21-server requires the default ruleset files to be readable at start. • civ2civ3/buildings.ruleset • civ2civ3/cities.ruleset • civ2civ3/effects.ruleset • civ2civ3/game.ruleset • civ2civ3/governments.ruleset • civ2civ3/nations.rulest • civ2civ3/styles.ruleset • civ2civ3/techs.ruleset • civ2civ3/terrain.ruleset • civ2civ3/units.ruleset • civ2civ3/script.lua • default/default.lua • default/nationlist.ruleset These files are for the default ruleset for the game (civ2civ3), which are loaded if you do not use the --ruleset argument. Alternate rules can be loaded with the rulesetdir directive in a start up script. Type help rulesetdir at the server command prompt for more information. If you are going to enable user authentication, you will need the data- base.lua file. The file is available on the GitHub repository (see be- low). ENVIRONMENT The Freeciv21 server accepts these environment variables: FREECIV_CAPS A string containing a list of "capabilities" provided by the server. The compiled default should be correct for most pur- poses, but if you are familiar with the capability string facil- ity in the source you may use it to enforce some constraints be- tween clients and server. FREECIV_COMPRESSION_LEVEL Sets the compression level for network traffic. FREECIV_MULTICAST_GROUP Sets the multicast group (for the LAN tab). FREECIV_DATA_PATH A colon separated list of directories pointing to the Freeciv21 data directories. By default Freeciv21 looks in the following directories, in order, for any data files: the current direc- tory; the "data" subdirectory of the current directory; the sub- directory ".local/share/freeciv21" in the user's home directory; and the directory where the files are placed by running "cmake --target install". FREECIV_SAVE_PATH A colon separated list of directories pointing to the Freeciv21 save directories. By default Freeciv21 looks in the following directories, in order, for save files: the current directory; and the subdirectory ".local/share/freeciv21/saves" in the user's home directory. (This does not affect where the server creates save game files. See the --saves option for that.) FREECIV_SCENARIO_PATH A colon separated list of directories pointing to the Freeciv21 scenario directories. By default Freeciv21 looks in the follow- ing directories, in order, for scenario files: the current di- rectory; the "data/scenarios" subdirectory of the current direc- tory; the subdirectory ".local/share/freeciv21/scenarios" in the user's home directory; and the directory where the files are placed by running "cmake --target install". (This does not affect where the server creates scenario files. See the --scenarios option for that.) HOME Specifies the user's home directory. For example, """- http://my_proxy_address/""". http_proxy Set this variable accordingly when using a proxy. LANG or LANGUAGE Sets the language and locale on some platforms. LC_ALL or LC_CTYPE Similar to LANG (see documentation for your system). USER Specifies the username of the current user. BUGS Please report bugs to the Freeciv21 bug tracker at https://github.com/longturn/freeciv21/issues/new/choose MORE INFORMATION See the Longturn home page at https://longturn.net/. You can also find the code repository at https://github.com/longturn/freeciv21/. AUTHOR Freeciv21 and Freeciv Contributors COPYRIGHT GPL-3.0-or-later, Freeciv21 and Freeciv Contributors Apr 13, 2025 FREECIV21-SERVER(6)
NAME | SYNOPSIS | DESCRIPTION | OPTIONS | EXAMPLES | FILES | ENVIRONMENT | BUGS | MORE INFORMATION | AUTHOR | COPYRIGHT
Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=freeciv21-server&sektion=6&manpath=FreeBSD+Ports+14.3.quarterly>
