Server configuration – ArmA: Armed Assault

From Bohemia Interactive Community
Jump to navigation Jump to search
m (→‎See Also: Removed underscores from links)
(→‎Windows: changed profile back to profile again as per suma, added boldness, important template)
Line 25: Line 25:
* Command line / link target:
* Command line / link target:
<pre>
<pre>
D:\ArmA\arma_server.exe -cfg=basic.cfg -config=server.cfg -profile=D:\ArmA\Users\server -name=server -mod=@mod1;@mod2
D:\ArmA\arma_server.exe -cfg=basic.cfg -config=server.cfg -profiles=D:\ArmA\Users\server -name=server -mod=@mod1;@mod2
</pre>
</pre>


Note: The parameter <pre>-profile=</pre> is correct when running the dedicated server, arma_server.exe
Using -profiles= will fail to set the dedicated server options.
Can someone clarify the use of -profiles (non-dedicated server?)


The parameter requires the explicit path to the directory containing the "server.armaprofile" file and the default location for this is "Drive:\Documents and Settings\UserName\My Documents\ArmA Other Profiles". You may find the required command is longer than that permissible in the Windows Shortcut Target: option.
The parameter requires the explicit path to the directory containing the "server.armaprofile" file and the default location for this is "Drive:\Documents and Settings\UserName\My Documents\ArmA Other Profiles". You may find the required command is longer than that permissible in the Windows Shortcut Target: option.
Line 39: Line 36:
Start in: "D:\ArmA"
Start in: "D:\ArmA"


Note the batch file name can be anything you wish, "ArmA_Server.cmd" is used in this example (the .cmd extension should be maintained).
Note that the batch file name can be anything you wish, "ArmA_Server.cmd" is used in this example (the .cmd extension should be maintained).
Batch file: ArmA_Server.cmd
Batch file: ArmA_Server.cmd


Contents:
'''Contents''':
<pre>
<pre>
D:\ArmA\arma_server.exe -cfg=basic.cfg -config=server.cfg -profile="D:\Documents and Settings\%UserName%\My Documents\ArmA" -mod=@mod1;@mod2
D:\ArmA\arma_server.exe -cfg=basic.cfg -config=server.cfg -profiles="D:\Documents and Settings\%UserName%\My Documents\ArmA" -mod=@mod1;@mod2
</pre>
</pre>


Tip:
{{Important|Tip: If you are running a public server, it is probably a good idea to enable logging using the parameter: -netlog }}
If you are running a public server, it is probably a good idea to enable logging using the parameter:
 
<pre>
This will record to a net.log file in the ArmA program directory, IP Address, Player name, mod's they are loading, net traffic and the Player ID which is very useful for dealing with troublemakers.
-netlog
 
</pre>
This will record to a net.log file in the ArmA program directory, IP Address, Player name, mod's they are loading, net traffic and the Player ID - very useful for dealing with troublemakers.
Be aware, the logs can grow large as they are not rotated, I would suggest doing this manually when the server is shutdown, or you could automate this in your startup batch file as follows: <pre>@if exist net.log goto rotatelog else end
Be aware, the logs can grow large as they are not rotated, I would suggest doing this manually when the server is shutdown, or you could automate this in your startup batch file as follows: <pre>@if exist net.log goto rotatelog else end


Line 67: Line 62:


:end
:end
"D:\Program Files\Bohemia Interactive\ArmA\arma_server.exe" -cfg=server_basic.cfg -config=server.cfg -mod=beta;DBE1;@mod1;@mod2 -profile="%HomeDrive%%HomePath%\My Documents\ArmA Other Profiles\public_server" -netlog -ranking=public_ranking.txt -maxmem=1024
"D:\Program Files\Bohemia Interactive\ArmA\arma_server.exe" -cfg=server_basic.cfg -config=server.cfg -mod=beta;DBE1;@mod1;@mod2 -profiles="%HomeDrive%%HomePath%\My Documents\ArmA Other Profiles\public_server" -netlog -ranking=public_ranking.txt -maxmem=1024
</pre>
</pre>
A directory named .\ArmA\NetLogs is required.
A directory named .\ArmA\NetLogs is required.
Change the delims specified for %str% to match your regional date settings, the example above uses the "." as the date separator.
Change the delims specified for %str% to match your regional date settings, the example above uses the "." as the date separator.
--[[User:Protegimus|Protegimus]] 01:50, 29 December 2007 (CET)


===Linux===
===Linux===

Revision as of 21:41, 31 December 2007

Introduction

Setting up a server is not easy and is not that obvious to do.

Basically, the server configuration consists of four elements:

Example Setups

Windows

Let's assume that ArmA is installed to "D:\Arma" and the Start in: property of the Windows shortcut is set to: "D:\Arma".

  • Command line / link target:
D:\ArmA\arma_server.exe -cfg=basic.cfg -config=server.cfg -profiles=D:\ArmA\Users\server -name=server -mod=@mod1;@mod2


The parameter requires the explicit path to the directory containing the "server.armaprofile" file and the default location for this is "Drive:\Documents and Settings\UserName\My Documents\ArmA Other Profiles". You may find the required command is longer than that permissible in the Windows Shortcut Target: option. If so, simply create a batch command file to start ArmA_Server and point the Shortcut to it:-

Shortcut properties (following the convention above where ArmA is installed to "D:\Arma", but this time the server profile is in the default "D:\Documents and Settings\%UserName%\My Documents\Arma" location): Target: D:\Batch\ArmA_Server.cmd Start in: "D:\ArmA"

Note that the batch file name can be anything you wish, "ArmA_Server.cmd" is used in this example (the .cmd extension should be maintained). Batch file: ArmA_Server.cmd

Contents:

D:\ArmA\arma_server.exe -cfg=basic.cfg -config=server.cfg -profiles="D:\Documents and Settings\%UserName%\My Documents\ArmA" -mod=@mod1;@mod2
Tip: If you are running a public server, it is probably a good idea to enable logging using the parameter: -netlog

This will record to a net.log file in the ArmA program directory, IP Address, Player name, mod's they are loading, net traffic and the Player ID which is very useful for dealing with troublemakers.

Be aware, the logs can grow large as they are not rotated, I would suggest doing this manually when the server is shutdown, or you could automate this in your startup batch file as follows:

@if exist net.log goto rotatelog else end

:rotatelog
set str=%date%
set tme=%time%
rem echo."%str%" "%tme%"
for /f "tokens=1,2,3* delims=." %%i in ("%str%") do set str=%%k%%j%%i
for /f "tokens=1,2,3* delims=:." %%i in ("%tme%") do set tme=%%i%%j%%k
rem echo."%str%" "%tme%"
move net.log .\NetLogs\%str%_%tme%_net.log
set str=
set tme=

:end
"D:\Program Files\Bohemia Interactive\ArmA\arma_server.exe" -cfg=server_basic.cfg -config=server.cfg -mod=beta;DBE1;@mod1;@mod2 -profiles="%HomeDrive%%HomePath%\My Documents\ArmA Other Profiles\public_server" -netlog -ranking=public_ranking.txt -maxmem=1024

A directory named .\ArmA\NetLogs is required. Change the delims specified for %str% to match your regional date settings, the example above uses the "." as the date separator.

Linux

Let's assume that ArmA is installed to "/usr/home/arma-server".

  • Command line / link target:
/usr/home/arma-server/server -cfg=basic.cfg -config=server.cfg -name=server -mod=@mod1\;@mod2\;@mod3

NOTE: this line is only for debugging. When you want to run the server permanently, edit and use the provided script "armaserver" that comes with the linux server files.

NOTE 2: the ';' denotes a line-end in Linux. So you have to put a backslash '\' in front of it to use multiple mods. Same if you use spaces in your directories: write 'my\ files'

Links

Example Setups at sir_hC

See Also

ArmA: Startup Parameters

Server Basic Config file

Server Config File

Server Difficulty Settings File


Multiplayer Server Commands

ArmA Community Tools


See also: ArmA: Version History