Dedicated Server – Arma 3

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "{{Feature|Informative|" to "{{Feature|informative|")
 
(73 intermediate revisions by 13 users not shown)
Line 1: Line 1:
{{TOC|side|0.9}}
{{Feature|arma2oa|For previous titles see [[Arma Dedicated Server]]}}
[[File:Arma 3_logo_black.png|200px|center]]
[[File:Arma 3_logo_black.png|200px|center]]


<span style="color:red"><b>WORK IN PROGRESS</b>
== <span style="color: #33D; font-weight: bold">Introduction</span> ==
<!--
<br> There is an issue with the anti spam system. When trying to add a link [url......] it wont allow the page to save and pops up the message
Your edit includes new external links. To help protect against automated spam, please type the two words you see in the box below:</span>
<span style="color:red">However there are no words and no box, so am unable to get past this problem.
<br> This is why all links ate defined as [ht tp..........  and not http...........
</span>
-->


==<span style="color:#0000ff"><b>Introduction</b></span>==
This page contains useful information on how to install and configure an ARMA 3 server and includes step by step guides of the install process. Also information on how to configure and run a server.
This page contains useful information on how to install and configure an ARMA 3 server and includes step by step guides of the install process. Also information on how to configure and run a server.
The majority of directories and paths are customizable, however those defined are all consistent with the tutorial instructions.
The majority of directories and paths are customizable, however those defined are all consistent with the tutorial instructions.
<br><br>
Much of the tutorial here was created using this guide from the forums http://forums.bistudio.com/showthread.php?147537-Tutorial-How-to-run-ArmA3-on-a-dedicated-server<br><br>


Note on steamCMD utility: if you are using it on a dedicated host to install and update Arma 3 dedicated server, it is a good practice to create a separate steam account for that. Arma 3 Dedicated server package is available for free (does not require regular Arma 3 to be purchased).
Much of the tutorial here was created using {{Link|link= https://forums.bohemia.net/forums/topic/139003-tutorial-installation-configuration-of-arma3-dedicated-server/|text= this forum guide}}.
 
{{Feature|informative|
About steamCMD utility: if you are using it on a dedicated host to install and update Arma 3 dedicated server, it is a good practice to create a separate steam account for that.
Arma 3 Dedicated server package is available for free (does not require regular Arma 3 to be purchased).
}}
 
 
== <span style="color: #33D; font-weight: bold">Installation</span> ==


==<span style="color:#0000ff"><b>Installation</b></span>==
=== Requirements ===


===Requirements===
# Steam Account
# Steam Account
# Supported Operating System
# Supported Operating System:
#* Windows: 2008 or later
#* Windows Server 2008 or later
#* A Modern Linux Distro
#* A modern Linux distribution
# Minimum Hardware:
# Minimum Hardware:
#* CPU:
:: {| class="wikitable"
#* RAM:
|+ {{Link|https://www.servermania.com/kb/articles/what-are-the-requirements-for-an-arma-3-server/|source}}
#* Disk
! Part
! Minimum
! Recommended
|-
| CPU
| 2.4 GHz Dual-Core
| 3.5 GHz Quad-Core
|-
| RAM
| 2GB
| 4GB
|-
| Storage
| 32 GB HDD
| 32 GB SSD
|}


===<span style="color:#B22222"><b>Instructions (Windows o/s)</b></span>===
{{Feature | Warning | {{arma3}} server does '''not''' support {{Link|https://en.wikipedia.org/wiki/IPv6}} or {{Link|https://en.wikipedia.org/wiki/IPv6_transition_mechanism#Dual-Stack_Lite_.28DS-Lite.29|DSlite IPv4 ''via'' IPv6 tunnel}}. You '''must''' have a '''real {{Link|https://en.wikipedia.org/wiki/IPv4}} connection'''.<br>If you are in doubt, contact your Internet Service Provider.}}


The following instructions will guide you through setting up one Arma 3 server on 1 box, however they will also set the foundations for installing multiple servers on that same box
=== <span style="color: #B22; font-weight: bold">Instructions (Windows o/s)</span> ===
# Install the latest version of [http://support.microsoft.com/kb/179113 DirectX]
 
The following instructions will guide you through setting up one Arma 3 server on 1 box, however they will also set the foundations for installing multiple servers on that same box:
# Install the latest version of {{Link|http://support.microsoft.com/kb/179113|DirectX}}
# Create the following empty directories
# Create the following empty directories
#* D:\Apps\Steam
#* D:\Apps\Steam
#* D:\Games\ArmA3\A3Master
#* D:\Games\ArmA3\A3Master
#* D:\Games\ArmA3\A3Files
#* D:\Games\ArmA3\A3Files
# Download [https://developer.valvesoftware.com/wiki/SteamCMD steamcmd.exe] and save it to your targetted Steam install directory (E.g <b>D:\Apps\Steam</b>)
# Download {{Link|https://developer.valvesoftware.com/wiki/SteamCMD|steamcmd.exe}} and save it to your targetted Steam install directory (E.g {{hl|D:\Apps\Steam}})
# Run the steamcmd.exe. (This will download and install the required steam files to your custom steam directory)
# Run the steamcmd.exe. (This will download and install the required steam files to your custom steam directory)
# Create an [[#Arma3server_steamcmd_example.cmd]] file and save it to D:\Games\ArmA3\A3Files
# Create an [[#Arma3server_steamcmd_example.cmd]] file and save it to D:\Games\ArmA3\A3Files
Line 47: Line 63:
# Create a shortcut for the ArmA3Server.exe on the server desktop
# Create a shortcut for the ArmA3Server.exe on the server desktop
# Add the following parameters to the Target Line in the shortcut tab of the newly created desktop shortcut
# Add the following parameters to the Target Line in the shortcut tab of the newly created desktop shortcut
#* -port=2302 (Required if running multiple server instances including any previous ArmA2 instances)
#* -port=2302 (Required if running multiple server instances including any previous Arma 2 instances)
#* "-profiles=d:\Games\Arma3\A3Master"
#* "-profiles=D:\Games\Arma3\A3Master"
#* -config=CONFIG_server.cfg
#* -config=CONFIG_server.cfg
#* -world=empty
#* -world=empty
#** so it looks something similar to the following
#** so it looks something similar to the following
#** "D:\Games\Arma3\A3Master\arma3server.exe" <b>"-profiles=d:\Games\Arma3\A3Master" -port=2302 -config=CONFIG_server.cfg -world=empty</b>
#** "D:\Games\Arma3\A3Master\arma3server.exe" '''"-profiles=D:\Games\Arma3\A3Master" -port=2302 -config=CONFIG_server.cfg -world=empty'''
# Setup the [[#Port Forwarding]] in your firewall accordingly
# Setup the [[#Port Forwarding]] in your firewall or\and router accordingly, also doesn't seems like implemented in some routers Port Trigger feature works with Arma 3 Server (tested with ASUS RT-N66U)
# Create a simple Notepad document called "[[#CONFIG_server.cfg|CONFIG_server.cfg]]" and save it to the root folder of your ArmA3 install on the server D:\Games\ArmA3\A3Master
# Make sure you have:
#* Network Discovery enabled for your network type (the setting can be found in [Control Panel\Network and Internet\Network and Sharing Center\Advanced sharing settings].<!--
--> If you have problem with its state reset on the interface reopen, check if all of the required for this feature services are running:<!--
--> DNS Client, Function Discovery Resource Publication, SSDP Discovery, UPnP Device Host; (makes server accessible from internet) (maybe it is about the services and not the network discovery)
#* Windows Media Player Network Sharing Service enabled (makes server joinable) ;
 
If you can't connect to server through server browser try to use "direct connect":
this is a client side issue (doesn't mean other clients will have it too), reason for the issue for now unknown,
I can say it is not related to: Windows services, Windows network settings, network routers, firewalls...
 
Device Host;
(note: Changes to the above 2 settings require Arma relaunch to be applied, as for server same for client machines;)
Create a simple Notepad document called "[[#CONFIG_server.cfg|CONFIG_server.cfg]]" and save it to the root folder of your ArmA3 install on the server D:\Games\ArmA3\A3Master
# Start up your shortcut, check the server runs. (You will see a console pop up in your desktop after a few seconds)
# Start up your shortcut, check the server runs. (You will see a console pop up in your desktop after a few seconds)
# Close the console window down, then you will need to edit the following files which will have been automatically created
# Close the console window down, then you will need to edit the following files which will have been automatically created
Line 61: Line 89:
# Restart the server
# Restart the server
# Start up your client Arma3.exe (Running the same branch as the server, (eg Stable or DEV) and you should then be able to see your server in the server browser (Filters are available to reduce the server list)
# Start up your client Arma3.exe (Running the same branch as the server, (eg Stable or DEV) and you should then be able to see your server in the server browser (Filters are available to reduce the server list)
# Login to your server using the password you defined in [[#CONFIG_server.cfg]] by typing "/" to open the chat window and then type (#login ADMINPASSWORD) followed by enter <pre style="color: red">Warning: Make sure you never forget the '#' in front of any server command!</pre>
# Login to your server using the password you defined in [[#CONFIG_server.cfg]] by typing "/" to open the chat window and then type (#login ADMINPASSWORD) followed by enter.{{Feature | Warning | Make sure to never forget the '#' in front of any server command!}}
# Once logged in you will be presented with a mission list, select one of the missions to start the game
# Once logged in you will be presented with a mission list, select one of the missions to start the game
# Prove the stability of your server by running BIS missions initially before you start adding user made content
# Prove the stability of your server by running BI missions initially before you start adding user made content


===<span style="color:#B22222"><b>Instructions (Linux o/s)</b></span>===
=== <span style="color: #B22; font-weight: bold">Instructions (Linux o/s)</span> ===
====Installation====


As a security best practice, create a user to run steam instead of running as root or an administrator. This way, if your ArmA server is compromised the attacker will find it more difficult to access the rest of the operating system.
==== Installation ====
<code>useradd -m -s /bin/bash steam</code>


Switch to the newly created steam user.  
As a security best practice, create a user to run steam instead of running as root or an administrator.
<code>sudo -i -u steam</code>
This way, if your ArmA server is compromised the attacker will find it more difficult to access the rest of the operating system.
useradd -m -s /bin/bash steam


Create a new directory for SteamCMD to avoid cluttering the home directory.  
Switch to the newly created steam user.
<code>mkdir ~/steamcmd && cd ~/steamcmd</code>
sudo -i -u steam


Download the [https://developer.valvesoftware.com/wiki/SteamCMD#Linux SteamCMD for Linux] tarball from the link at the Valve Developer Community page. Use a command line download tool such as <tt>wget</tt> or <tt>curl</tt>.
Create a new directory for SteamCMD to avoid cluttering the home directory.
mkdir ~/steamcmd && cd ~/steamcmd
 
Download the {{Link|https://developer.valvesoftware.com/wiki/SteamCMD#Linux|SteamCMD for Linux}} tarball from the link at the Valve Developer Community page.
Use a command line download tool such as {{hl|wget}} or {{hl|curl}}.


Extract the tarball.
Extract the tarball.
<code>tar xf steamcmd_linux.tar.gz</code>
tar xf steamcmd_linux.tar.gz


Execute steamcmd.sh. It will install the rest of the Steam client and start the Steam client shell. If this step fails on a 64-bit OS, you likely need to [https://developer.valvesoftware.com/wiki/SteamCMD#32-bit_libraries_on_64-bit_Linux_systems install 32-bit libraries].
Execute steamcmd.sh. It will install the rest of the Steam client and start the Steam client shell.
<code>./steamcmd.sh</code>
If this step fails on a 64-bit OS, you likely need to {{Link|https://developer.valvesoftware.com/wiki/SteamCMD#32-bit_libraries_on_64-bit_Linux_systems|install 32-bit libraries}}.
./steamcmd.sh


At the Steam client shell, login with a valid Steam username and password. [https://developer.valvesoftware.com/wiki/SteamCMD#SteamCMD_Login The Valve Developer Community Wiki recommends that you create a new Steam account for this.] SteamCMD will cache the login credentials and anyone who gains access to your server will be able to log into the account used here. In addition, you cannot log into a single Steam account from two places at once. You do not need to have Arma 3 purchased on the Steam account used here to download the server. Therefore, you should create a new Steam account with no purchases only for use on this server.
Change the directory SteamCMD will install the server in.
<code>login myusername</code>
force_install_dir ./arma3/


Change the directory SteamCMD will install the server in.
At the Steam client shell, login with a valid Steam username and password.
<code>force_install_dir ./arma3/</code>
The Valve Developer Community Wiki {{Link|https://developer.valvesoftware.com/wiki/SteamCMD#SteamCMD_Login|recommends that you create a new Steam account for this}}.
SteamCMD will cache the login credentials and anyone who gains access to your server will be able to log into the account used here.
In addition, you cannot log into a single Steam account from two places at once. You do not need to have Arma 3 purchased on the Steam account used here to download the server.
Therefore, you should create a new Steam account with no purchases only for use on this server.
login myusername


Install the Arma 3 Linux dedicated server. The validate option will check for corruption.
Install the Arma 3 Linux dedicated server. The validate option will check for corruption.
<code>app_update 233780 validate</code>
app_update 233780 validate


Exit SteamCMD.
Exit SteamCMD.
<code>exit</code>
exit


Create the directories used to store the profile files and Arma3.cfg file.
Create the directories used to store the profile files and Arma3.cfg file.
<code>mkdir -p ~/".local/share/Arma 3" && mkdir -p ~/".local/share/Arma 3 - Other Profiles"</code>
mkdir -p ~/".local/share/Arma 3" && mkdir -p ~/".local/share/Arma 3 - Other Profiles"


note: create a symlink called "MPmissions" pointing to "mpmissions" to solve RANDOM SEGFAULTS
==== Updating ====
            ln -s /<path to a3server directory>/mpmissions /<path to a3server directory>/MPMissions
 
====Updating====


You will have to update the server whenever a patch is released on Steam.
You will have to update the server whenever a patch is released on Steam.


If the server is running, stop it by pressing Ctrl+C in the terminal (or screen/tmux instance) that the server is attached to. Otherwise, switch to the steam user.
If the server is running, stop it by pressing Ctrl+C in the terminal (or screen/tmux instance) that the server is attached to. Otherwise, switch to the steam user.
<code>sudo -u steam -i</code>
sudo -u steam -i


Launch steamcmd.
Launch steamcmd.
<code> cd /home/steam/steamcmd</code>
cd /home/steam/steamcmd
<code>./steamcmd.sh</code>
./steamcmd.sh
 
Set the Arma 3 installation directory to the same directory used above.
force_install_dir ./arma3/


Login to the Steam account used in the installation section above.
Login to the Steam account used in the installation section above.
<code>login myusername</code>
login myusername
 
Set the ArmA 3 installation directory to the same directory used above.
<code>force_install_dir ./arma3/</code>


Update the Arma 3 Linux dedicated server. The validate option will check for corruption.
Update the Arma 3 Linux dedicated server. The validate option will check for corruption.
<code>app_update 233780 validate</code>
app_update 233780 validate


Exit SteamCMD.
Exit SteamCMD.
<code>exit</code>
exit
 
==== Configuration ====


====Configuration====
You will most likely want to customize your server's name, password, security settings, and so on with a server.cfg file. Change to the arma3 directory and create and edit your server.cfg file.
cd ~/steamcmd/arma3
vim server.cfg
If you don't know how to use vim, use nano instead.
nano server.cfg


You will most likely want to customize your server's name, password, security settings, and so on with a server.cfg file. Change to the arma3 directory and create and edit your server.cfg file.
<code>cd ~/steamcmd/arma3</code>
<code>vim server.cfg</code>
If you don't know how to use vim, use nano instead.
<code>nano server.cfg</code>
See [[server.cfg]] for documentation and examples.
See [[server.cfg]] for documentation and examples.


The first time you run the server it will auto-create a profile file at <tt>~/.local/share/Arma 3 - Other Profiles/server/server.Arma3Profile</tt>. Edit this file to customize difficulty settings. NB: the -profiles= parameter is broken on Linux - you must place your profiles in this directory.
The first time you run the server it will auto-create a profile file at {{hl|~/.local/share/Arma 3 - Other Profiles/server/server.Arma3Profile}}.
Edit this file to customize difficulty settings.
{{Feature | important | The {{hl|c= -profiles{{=}}}} parameter is broken on Linux - you '''must''' place your profiles in this directory.}}


====Launching====
==== Launching ====


A Linux executable is provided to launch the server. Make sure that you are running it under the steam user and not root or another administrator!
A Linux executable is provided to launch the server. Make sure that you are running it under the steam user and not root or another administrator!
<code>cd /home/steam/steamcmd/arma3</code>
cd /home/steam/steamcmd/arma3
<code>./arma3server -name=server -config=server.cfg</code>
./arma3server_x64 -name=server -config=server.cfg


NB: If you are using the -mods= parameter, you must specify relative paths rather than absolute paths.
NB: If you are using the {{hl|c= -mod=}} parameter, you must specify relative paths ''within or below'' the Arma 3 directory. Symlinks will work.
The arma3server process will attach to the current terminal. If you are connected to the server over SSH, the server will stop when you disconnect. You can keep the server running in the background using [https://www.gnu.org/software/screen/ GNU Screen] or [http://tmux.sourceforge.net/ tmux]. There are many tutorials online on how to use these programs to detach and reattach processes from and to a terminal.  


You can safely stop the server by pressing Ctrl+C in the terminal (or screen/tmux instance) that the server is attached to.  
The arma3server_x64 process will attach to the current terminal.
If you are connected to the server over SSH, the server will stop when you disconnect.
You can keep the server running using a terminal multiplexeer like {{Link|https://www.gnu.org/software/screen/|GNU Screen}} or {{Link|http://tmux.sourceforge.net/|tmux}}.
There are many tutorials online on how to use these programs to detach and reattach processes from and to a terminal.


====Case sensitivity & Mods====
You can safely stop the server by pressing Ctrl+C in the terminal (or screen/tmux instance) that the server is attached to.
Some mods such as @ALiVE and @A3MP will not function if there are capital letters in any of their file names. If you do not update your mods on a regular basis, you can just use the command
 
<code>find . -depth -exec rename 's/(.*)\/([^\/]*)/$1\/\L$2/' {} \;</code>
For older 32-bit executable use ./arma3server instead of ./arma3server_x64.
 
==== Case sensitivity & Mods ====
 
Some mods such as CUP Terrains and @ALiVE will not function if there are capital letters in any of their file names. If you do not update your mods on a regular basis, you can just use the command
find . -depth -exec rename 's/(.*)\/([^\/]*)/$1\/\L$2/' {} \;
in the directory where your mods are located. This will recursively search the directory tree and make all the filenames lowercase.
in the directory where your mods are located. This will recursively search the directory tree and make all the filenames lowercase.


If you regularly update your mods using, e.g. ArmA3Sync, you will find that this will redownload any files/folders that have changed case every time you run it. The solution to this is to use a package called "ciopfs" - Case Insensitive On Purpose Filesystem. You should first run the "find . -depth..." command mentioned above on your mod folder. Then, make an empty directory outside of the mods directory, e.g. mods_caseinsensitive. You then mount the directory with
If you regularly update your mods using, e.g. ArmA3Sync, you will find that this will redownload any files/folders that have changed case every time you run it.
<code>ciopfs mods mods_caseinsensitive</code>
The solution to this is to use a package called "ciopfs" - Case Insensitive On Purpose Filesystem. You should first run the "find . -depth..." command mentioned above on your mod folder.
and tell ArmA3Sync to synchronise in the mods_caseinsensitive directory. Once it has finished, you can unmount the directory with
Then, make an empty directory outside of the mods directory, e.g. mods_caseinsensitive. You then mount the directory with:
<code>fusermount -u mods_caseinsensitive</code>
ciopfs mods mods_caseinsensitive
 
and tell ArmA3Sync to synchronise in the mods_caseinsensitive directory. Once it has finished, you can unmount the directory with:
fusermount -u mods_caseinsensitive
 
You should find that all of the files in the original mods directory are lowercase.
You should find that all of the files in the original mods directory are lowercase.
{{Wiki|stub}}


<span style="color:red"><b>WORK IN PROGRESS</b></span>
== <span style="color: #33D; font-weight: bold">Additional Info</span> ==


==<span style="color:#0000ff"><b>Additional Info</b></span>==
=== <span style="color: #B22; font-weight: bold">Useful Links</span> ===


===<span style="color:#B22222"><b>Useful Links</b></span>===
==== Further Reading ====


====Further Reading====
* {{Link|https://developer.valvesoftware.com/wiki/SteamCMD|Steam Cmd Tutorial}}
* [https://developer.valvesoftware.com/wiki/SteamCMD Steam Cmd Tutorial]
* {{Link|link= https://forums.bohemia.net/forums/topic/139605-dedicated-server-status/|text= Dedicated Server Status (Linux info)}}
* [http://forums.bistudio.com/showthread.php?148288-Dedicated-server-status Dedicated Server Status (Linux info)]
* {{Link|http://www.kellys-heroes.eu/files/tutorials/dedicated/arma3dedicated.php#one|Kelly's Heroes Dedicated server guide}}
* [http://www.kellys-heroes.eu/files/tutorials/dedicated/arma3dedicated.php#one Kelly's Heroes Dedicated server guide]
* [[In_Game_Server_Commands|In Game server commands]]
* [[In_Game_Server_Commands|In Game server commands]]
* [[Multiplayer_Server_Commands|In Game admin commands]]
* [[Multiplayer_Server_Commands|In Game admin commands]]
* [[Arma2:_Startup_Parameters|Command line params]]
* [[Arma 2: Startup Parameters|Command line params]]
* [[basic.cfg|Basic.cfg]]
* [[basic.cfg|Basic.cfg]]
* [[server.armaprofile|Steam Difficulty settings]]
* [[server.armaprofile|Steam Difficulty settings]]
* [[ArmA:_Server_configuration|Server Configuration]]
* [[ArmA:_Server_configuration|Server Configuration]]
* [https://code.google.com/p/symlinker/ Sim-link GUI]
* {{Link|https://code.google.com/p/symlinker/|Sim-link GUI}}
 
==== Tools ====


====Tools====
* {{Link|http://www.firedaemon.com/|Firedeamon}}
* [http://www.youtube.com/watch?v{{=}}37ifEKAZqlM&feature ArmA3 server using TA2DST Method]<br><!--
-->A YouTube video tutorial by Kirkwood364 which uses Tophe's Arma 2 Dedicated Server Tool to administer and run an A3 server<!--
--> (Links for all the files required are available in the 1st comment of his YouTube video)
* {{Link|link= https://forums.bohemia.net/forums/topic/146822-arma-server-monitor-very-small-but-useful/|text= Arma3 Server Monitor}} - ''end of support in 2015''


* [http://forums.bistudio.com/showthread.php?155881-Arma-Server-Monitor-(very-small-but-useful) Arma3 Server Monitor]
==== Useful Addons ====
* [http://www.firedaemon.com/ Firedeamon]
* [http://www.youtube.com/watch?v=37ifEKAZqlM&feature ArmA3 server using TA2DST Method]
** A You-Tube video tutorial by Kirkwood364 which uses Tophe's Arma 2 Dedicated Server Tool to administer and run an A3 server
** (Links for all the files required are available in the 1st comment of his You-Tube video)
* [http://forums.bistudio.com/showthread.php?155881-Arma-Server-Monitor-(very-small-but-useful) arma3server for Linux]
** arma3server is a command line tool for quick, simple deployment and management of a ARMA 3 Linux dedicated server.


====Useful Addons====
* {{Link|link= https://forums.bohemia.net/forums/topic/143462-zeu_serverskill-serverside-ai-skill-setting-addon-with-userconfig-configuration/|text= Zeu_Serverskills}} (AI Skill setting addon)
* [http://forums.bistudio.com/showthread.php?152393-zeu_ServerSkill-(Serverside-AI-skill-setting-addon-with-userconfig-configuration) Zeu_Serverskills] (AI Skill setting addon)
* {{Link|link= https://forums.bohemia.net/forums/topic/141073-zeu_a3serverbriefing-a-serverside-addon/|text= Zeu_ServerBriefing}} (Inject server information to all missions automatically
* [http://forums.bistudio.com/showthread.php?149882-zeu_A3ServerBriefing-(-A-Serverside-addon) Zeu_ServerBriefing] (Inject server information to all missions automatically
 
=== <span style="color: #B22; font-weight: bold">File Locations</span> ===


===<span style="color:#B22222"><b>File Locations</b></span>===
Some files are automatically created when you use certain commandline parameters
Some files are automatically created when you use certain commandline parameters
Some files have to be created manually.
Some files have to be created manually.
If you have followed the instructions accurately, you will now have the following files and directories in addition to the clean install
If you have followed the instructions accurately, you will now have the following files and directories in addition to the clean install


* d:\Games\Arma3\A3Master\   <span style="color:#000080">Users\Administrator\<b>Administrator.Arma3Profile</b></span> ''(Difficulty settings)''
* D:\Games\Arma3\A3Master\{{Color|#000080|Users\Administrator\'''Administrator.Arma3Profile'''}} ''(Difficulty settings)''
* d:\Games\Arma3\A3Master\   <span style="color:#000080">Users\Administrator\<b>Administrator.vars.Arma3Profile</b></span> ''(Some binarised content which you cannot edit)''
* D:\Games\Arma3\A3Master\{{Color|#000080|Users\Administrator\'''Administrator.vars.Arma3Profile'''}} ''(Some binarised content which you cannot edit)''
* d:\Games\Arma3\A3Master\   <span style="color:#000080">Users\Administrator\<b>Arma3.cfg</b></span> ''(Bandwidth settings)''
* D:\Games\Arma3\A3Master\{{Color|#000080|Users\Administrator\'''Arma3.cfg'''}} ''(Bandwidth settings)''
* d:\Games\Arma3\A3Master\   <span style="color:#000080"><b>MPMissions\</b></span> ''This is where custom made mission.pbo's need to be placed) ''
* D:\Games\Arma3\A3Master\{{Color|#000080|'''MPMissions\'''}} ''(This is where custom made mission.pbo's need to be placed)''
* d:\Games\Arma3\A3Master\   <span style="color:#000080"><b>arma3.rpt</b></span> ''(Debug Log, automatically created every time the arma3server.exe is started)''
* D:\Games\Arma3\A3Master\{{Color|#000080|'''arma3.rpt'''}} ''(Debug Log, automatically created every time the arma3server.exe is started)''
* d:\Games\Arma3\A3Master\   <span style="color:#000080"><b>CONFIG_server.cfg</b></span> ''(Manually created)''
* D:\Games\Arma3\A3Master\{{Color|#000080|'''CONFIG_server.cfg'''}} ''(Manually created)''
* d:\Games\ArmA3\A3Files\   <span style="color:#000080"><b>Arma3server_steamcmd_example.cmd</b></span> ''(Manually created)''
* D:\Games\ArmA3\A3Files\{{Color|#000080|'''Arma3server_steamcmd_example.cmd'''}} ''(Manually created)''
* d:\Apps\Steam\
* D:\Apps\Steam\
 
 
=== <span style="color: #B22; font-weight: bold">Port Forwarding</span> ===
 
Arma 3 uses the same default ports as Arma 2 with the addition of several ports. So if you intend running A2 and A3 servers on the same machine, you need to edit the ports used.
'''Default ports are all UDP''' and as follows:


===<span style="color:#B22222"><b>Port Forwarding</b></span>===
; Incoming:
* 2302 (default Arma 3 Game port) + (VON is now part of main gameport due to NAT issues)
* 2303 (STEAM query, +1)
* 2304 (Steam port, +2)
* 2305 (VON port, +3 - not used atm. but allocated)
* 2306 (BattlEye traffic, +4)


Arma 3 uses the same default ports as Arma 2 with the addition of 2 steam ports. So if you intend running A2 and A3 servers on the same machine, you need to edit the ports used.
; Outgoing:
'''Default ports are all UDP''' and as follows
{| class="wikitable"
<br /><b>Incoming:</b>
* 2302 (Arma3 Game port) + (VON is now part of main gameport due to NAT issues)
* 2303 (STEAM query )
* 2304 (Steam port)
* 2305 (VON port - not used atm. but allocated)
<b>Outgoing:</b><br />
{| class="bikitable"
|-
|-
!DST Port
!DST Port
!Proto
!Protocol
!Destination
!Destination
!Comment
!Comment
|-
|-
|2344
|2344
|TCP+UDP
|TCP + UDP
|81.0.236.111
|81.0.236.111
|BattlEye - arma31.battleye.com
|BattlEye - arma31.battleye.com
Line 232: Line 285:
|BattlEye - arma31.battleye.com
|BattlEye - arma31.battleye.com
|-
|-
|2302-2305
|2302-2306
|UDP
|UDP
|any
|any
Line 248: Line 301:
|}
|}


<br /><br />
<br><br>
To define the ArmA3 Game port used,  
To define the ArmA3 Game port used,
state -port= **** in your command line arguments (Where *** is the new initial Arma 3 Game eg 2302)
state -port= **** in your command line arguments (Where **** is the new initial Arma 3 Game, e.g 2302)


and to define your Steam ports
and to define your Steam ports
add the following lines to your CONFIG_server.cfg (editing the actual port numbers as required)
add the following lines to your CONFIG_server.cfg (editing the actual port numbers as required)


// STEAM ports are now linked to game-port as +1 for query and +2 to-master
{{Feature | Informative | STEAM ports are now linked to game-port as +1 for query and +2 to-master.}}


If you are running multiple servers, i would suggest the following format
If you are running multiple servers, i would suggest the following format


<b><u>SERVER 1</u></b>
; SERVER 1
<br>2302 UDP (gameport + VON)
<br>2302 UDP (gameport + VON)
<br>2303 UDP (STEAM query port)
<br>2303 UDP (STEAM query port)
<br>2304 UDP (STEAM master port)
<br>2304 UDP (STEAM master port)
<br>2305 UDP (VON reserved port but not used atm.)
<br>2305 UDP (VON reserved port but not used atm.)
<br>so open ports 2302-2305
<br>2306 UDP (BattlEye traffic port)
<br>and leave at least 10 ports between the next server set
<br>so open ports 2302-2306
<br>... and leave at least '''100''' ports between the next 2<sup>nd</sup> server set
<br>
 
; SERVER 2
<br>2402 UDP (gameport + VON)
<br>2403 UDP (STEAM query port)
<br>2404 UDP (STEAM master port)
<br>2405 UDP (VON reserved port but not used atm.)
<br>2406 UDP (BattlEye traffic port)
<br>so open ports 2402-2406
<br>and leave at least '''100''' ports between the next 3<sup>rd</sup> server set, etc.


<b><u>SERVER 2</u></b>
==== NAT traversal ====
<br>2312 UDP (gameport + VON)
<br>2313 UDP (STEAM query port)
<br>2314 UDP (STEAM master port)
<br>2315 UDP (VON reserved port but not used atm.)
<br>so open ports 2312-2315
<br>and leave at least 10 ports between the next 3rd server set etc.


====NAT traversal====
UPnP allows you to automatically create port forwarding on your router to bypass NAT (UPnP enabled routers are required).
UPnP allows you to automatically create port forwarding on your router to bypass NAT (UPnP enabled routers are required). The functionality can be easily enabled in server config as described in the [[server.cfg#Server_Options | server.cfg]] page.
The functionality can be easily enabled in server config as described in the [[server.cfg#Server_Options | server.cfg]] page.


===<span style="color:#B22222"><b>Configuring for stable or Dev branch</b></span>===
=== <span style="color: #B22; font-weight: bold">Configuring for stable or Dev branch</span> ===


Edit the Arma3server_steamcmd_example.cmd as defined below then run it
Edit the Arma3server_steamcmd_example.cmd as defined below then run it
Line 289: Line 347:
  SET A3BRANCH=107410
  SET A3BRANCH=107410


<b>Important Feature</b>
; Important Feature
Since 12th March 2013 the development branch and the stable branch versions are no longer compatible. this means:
Since '''12<sup>th</sup> March 2013''' the development branch and the stable branch versions are no longer compatible. This means:
<br>Only DEV clients can connect to a DEV server
* Only DEV clients can connect to a DEV server
<br>Only Stable clients can connect to stable servers
* Only Stable clients can connect to stable servers
 
=== <span style="color: #B22; font-weight: bold">Advanced Configuration</span> ===
 
{{Wiki|stub}}


===<span style="color:#B22222"><b>Advanced Configuration</b></span>===
=== <span style="color: #B22; font-weight: bold">Bandwidth Optimisation</span> ===
<span style="color:red"><b>WORK IN PROGRESS</b></span>


===<span style="color:#B22222"><b>Bandwidth Optimisation</b></span>===
{{Wiki|stub}}
<span style="color:red"><b>WORK IN PROGRESS</b></span>


===<span style="color:#B22222"><b>Multiple Server configuration</b></span>===
=== <span style="color: #B22; font-weight: bold">Multiple Server configuration</span> ===


There are various methods available to run multiple Dedicated Arma 3 servers on the same box.
There are various methods available to run multiple Dedicated Arma 3 servers on the same box.
Each server instance requires  
Each server instance requires:
*Its own unique set of ports
* Its own unique set of ports
*Its own profile
* Its own profile
*Its own config
* Its own config


This [http://forums.bistudio.com/showthread.php?147537-Tutorial-How-to-run-ArmA3-server-on-a-dedicated-server&p=2402555&viewfull=1#post2402555 Post] explains it more in depth
{{Link|link= https://forums.bohemia.net/forums/topic/139003-tutorial-installation-configuration-of-arma3-dedicated-server/?page=10&tab=comments#comment-2344472|text= This post}} explains it more in depth.


Each method has some pro's and cons
Each method has some pro's and cons
Line 317: Line 377:
* Update management
* Update management


====<b><u>METHOD 1</u></b>====
==== <span style="font-weight: bold; text-decoration: underline">METHOD 1</span> ====


see [http://forums.bistudio.com/showthread.php?147537-Tutorial-How-to-run-ArmA3-server-on-a-dedicated-server&p=2401936&viewfull=1#post2401936 THIS POST] for more detailed information
see {{Link|link= https://forums.bohemia.net/forums/topic/139003-tutorial-installation-configuration-of-arma3-dedicated-server/?page=9&tab=comments#comment-2343865|text= THIS POST}} for more detailed information
This is copy of the master install into a different directory
This is copy of the master install into a different directory
As may times as you have space for
As may times as you have space for


<b>Pros</b>
'''Pros'''
* Most robust
* Most robust
* Unique MpMissions folder
* Unique MpMissions folder
* Unique "keys" folder
* Unique "keys" folder
* Allows ability to run seperate instances of different branches of the game, (E.g Dev or Stable)
* Allows ability to run separate instances of different branches of the game, (E.g Dev or Stable)


<b>Cons</b>
'''Cons'''
* Uses more drive space
* Uses more drive space
* Requires more effort to create and automate the updating process
* Requires more effort to create and automate the updating process


====<b><u>METHOD 2</u></b>====
==== <span style="font-weight: bold; text-decoration: underline">METHOD 2</span> ====


This uses 1 master install folder and has renamed arma3server.exe's in sub folders of the master
This uses 1 master install folder and has renamed arma3server.exe's in sub folders of the master
see THIS POST for more detailed information
see THIS POST for more detailed information


<b>Pros</b> (Compared to Method 1)
'''Pros''' (Compared to Method 1)
* Uses less space than Method 1
* Uses less space than Method 1
* Updating will be easier
* Updating will be easier


<b>Cons</b> (Compared to Method 1)
'''Cons''' (Compared to Method 1)
* Not very Robust
* Not very robust
* Shares MpMissions folders with all the other exe's (Will create a very cluttered MpMissions folder and allows admins to select addon required missions for a mod this server instance isn't running
* Shares MPMissions folders with all the other exe's (Will create a very cluttered MpMissions folder and allows admins to select addon required missions for a mod this server instance isn't running
* Shares "keys" folder with all other exe's (This can cause an issue when running various differing -mod servers)
* Shares "keys" folder with all other exe's (This can cause an issue when running various differing -mod servers)
* Will not allow you to run seperate instances of different branches of the game
* Will not allow you to run separate instances of different branches of the game


====<b><u>METHOD 3</u></b>====
==== <span style="font-weight: bold; text-decoration: underline">METHOD 3</span> ====


This is a hybrid of method 1, in that it is essentially a "Virtual" copy of the master install in a different directory
This is a hybrid of method 1, in that it is essentially a "Virtual" copy of the master install in a different directory
the difference being that many folders are [http://en.wikipedia.org/wiki/Symbolic_link sim linked] to the initial Master directory
the difference being that many folders are {{Link|https://en.wikipedia.org/wiki/Symbolic_link|sim linked}} to the initial Master directory
simlink GUI:
simlink GUI:


<b>Pros</b> (Compared to Method 1)
'''Pros''' (Compared to Method 1)
* Uses less drive space (As you wont have multiple copies of the addons folder)
* Uses less drive space (As you wont have multiple copies of the addons folder)
* Allows for unique MpMissions folder if desired
* Allows for unique MpMissions folder if desired
Line 360: Line 420:
* Updating will be easier
* Updating will be easier


<b>Cons</b> (Compared to Method 1)
'''Cons''' (Compared to Method 1)
* Requires more effort to initially create the simlinks and directories
* Requires more effort to initially create the simlinks and directories
* Will not allow you to run seperate instances of different branches of the game at the same time, (E.g Dev or Stable)
* Will not allow you to run separate instances of different branches of the game at the same time, (E.g Dev or Stable)
 
For example, on Linux, if you initially have the following folder layout:
 
~/game_servers/
arma3server/
...
mods # folder where you keep your mods
arma3server
...
 
Instead of copying the folders as directed in METHOD 1, run the following commands:


====<b><u>METHOD 4</u></b>====
<syntaxhighlight lang="batch">
cd ~/game_servers/
mkdir arma3server_2/
ln -sr arma3server/* arma3server_2
cd arma3server_2
rm keys mpmissions mods
mkdir keys
mkdir mpmissions
mkdir mods
</syntaxhighlight>


You could of course mix n match all 3 methods to suit your specific requirements
Then proceed with the rest of the instructions in METHOD 1.


==== <span style="font-weight: bold; text-decoration: underline">METHOD 4</span> ====
You can of course mix and match all 3 previous methods to suit your specific requirements.
=== <span style="color: #B22; font-weight: bold">Dedicated Server & Client configuration</span> ===
{{Feature|informative|In order for the {{arma3}} server to be able to connect to the Steam servers, the {{arma3}} server has to be ping-able (ICMP 8 - Echo Reply) as well as opened TCP/UDP ports.}}


===<span style="color:#B22222"><b>Dedicated Server & Client configuration</b></span>===
The only known issue, is to make sure you start the server up before you start the steam client
The only known issue, is to make sure you start the server up before you start the steam client
Failing to do this causes steam port issues and your client will not be able to connect to the server
Failing to do this causes steam port issues and your client will not be able to connect to the server


===<span style="color:#B22222"><b>Headless Client</b></span>===
=== <span style="color: #B22; font-weight: bold">Headless Client</span> ===
<span style="color:#B22222"><b>New:</b></span> See [[Arma 3 Headless Client]] for changes in headless clients ('''TODO: update this section accordingly''')


--[[User:JacmacBrian|JacmacBrian]] ([[User talk:JacmacBrian|talk]]) 22:14, 23 February 2014 (CET)
{{Feature | Informative | See [[Arma 3 Headless Client]] for changes in headless clients.}}
{{Wiki|stub}}


A Headless Client can be used by missions to offload AI processing to a dedicated client, freeing up the dedicated server process from most AI processing. Thus more AI units can be spawned and the server process will be able to dedicate most of it's processing towards communication with the clients. For a Headless Client/Dedicated Server to function together efficiently, they both need to be connected to each other via extremely low latency and high bandwidth. Effectively, they need to be on the same LAN at least, but preferably running on the same computer.
A Headless Client can be used by missions to offload AI processing to a dedicated client, freeing up the dedicated server process from most AI processing.
Thus more AI units can be spawned and the server process will be able to dedicate most of it is processing towards communication with the clients.
For a Headless Client/Dedicated Server to function together efficiently, they both need to be connected to each other via extremely low latency and high bandwidth.
Effectively, they need to be on the same LAN at least, but preferably running on the same computer.


====Setup and Execution====
==== Setup and Execution ====


* Headless Client for ARMA 3 requires a '''valid active Steam account logged in''' to function ([http://forums.bistudio.com/showthread.php?149412-Arma-3-Headless-Client&p=2544027&viewfull=1#post2544027 Dwarden Post])
* Headless Client for ARMA 3 requires a '''valid active Steam account logged in''' to function<!--
--> (see {{Link|link= https://forums.bohemia.net/forums/topic/140621-arma-3-headless-client/?page=5&tab=comments#comment-2481581|text= Dwarden's post}})
* A Headless Client is simply Arma3.exe run from the command line with parameters, for example:
* A Headless Client is simply Arma3.exe run from the command line with parameters, for example:
<pre>
<syntaxhighlight lang="cpp">
arma3.exe -connect=localhost -port=2444 -client -nosound -password=some_server_password -name=HC -profile=HC -mod=@CBA_A3;@blah;@blah;@blah
arma3.exe -connect=localhost -port=2444 -client -nosound -password=some_server_password -name=HC -profile=HC -mod=@CBA_A3;@blah;@blah;@blah
</pre>
</syntaxhighlight>


In the example above, the headless client is running on the same host as the dedicated server. It uses a profile called '''HC''' and connects to the server with a password as required by the server (the password is for password protected servers, optional). The server in this example is running on port 2444, alter this to the port of your server.
In the example above, the headless client is running on the same host as the dedicated server.
It uses a profile called '''HC''' and connects to the server with a password as required by the server (the password is for password protected servers, optional).
The server in this example is running on port 2444, alter this to the port of your server.


* The Headless Client profile needs to be created like any other profile in Arma 3 (Note: It is best if you name this profile '''HC''')
* The Headless Client profile needs to be created like any other profile in Arma 3 (Note: It is best if you name this profile '''HC''')
No configuration of the profile is necessary, but after creation, edit '''HC.Arma3Profile''' located in '''C:\Users\yourusername\Documents\Arma 3 - Other Profiles\HC''' and add this line:
No configuration of the profile is necessary, but after creation, edit '''HC.Arma3Profile''' located in '''C:\Users\yourusername\Documents\Arma 3 - Other Profiles\HC''' and add this line:
<pre>
<syntaxhighlight lang="cpp">
battleyeLicense=1;
battleyeLicense=1;
</pre>
</syntaxhighlight>


Alternatively, you can use the full Arma 3 client to connect to any multiplayer server with BattlEye enabled and accept the BattlEye License Agreement, which will do the same thing as manually editing '''HC.Arma3Profile'''.
Alternatively, you can use the full Arma 3 client to connect to any multiplayer server with BattlEye enabled and accept the BattlEye License Agreement,
which will do the same thing as manually editing '''HC.Arma3Profile'''.


Once the profile is ready, copy the profile directory to '''C:\Users\yourusername\Documents\Arma 3 - Other Profiles''' on the server (if the profile was not created on the server). If the profile was created on the server or is not going to run on the server and is already on the computer it is going to run on, then it is ready to go.
Once the profile is ready, copy the profile directory to '''C:\Users\yourusername\Documents\Arma 3 - Other Profiles''' on the server (if the profile was not created on the server).
If the profile was created on the server or is not going to run on the server and is already on the computer it is going to run on, then it is ready to go.


* If the Headless Client is on the server, the server's cfg must have the local loopback address as seen below (e.g. A3Server.cfg):
* If the Headless Client is on the server, the server's cfg must have the local loopback address as seen below (e.g. A3Server.cfg):
<pre>
<syntaxhighlight lang="cpp">
localClient[]={"127.0.0.1"};
localClient[]={"127.0.0.1"};
headlessClients[]={"127.0.0.1"};
headlessClients[]={"127.0.0.1"};
battleyeLicense=1;
battleyeLicense=1;
</pre>
</syntaxhighlight>
Dwarden suggests that '''battleyeLicense=1;''' be in the server's config, but it is unclear whether this is actually necessary. ([http://forums.bistudio.com/showthread.php?160029-Headless-client-battleye&p=2473647&viewfull=1#post2473647 Dwarden Post])
Dwarden suggests that '''battleyeLicense=1;''' be in the server's config, but it is unclear whether this is actually necessary.
({{Link|link= https://forums.bohemia.net/forums/topic/150815-headless-client-battleye/?tab=comments#comment-2413319|text= Dwarden's post}}).


* If the Headless Client is running in the same network or the same computer, the server's config has to have the address in '''localClient[]=x.x.x.x'''. This will allow the server to communicate with the Headless Client using unrestricted bandwidth. It is also required to add the adress to '''headlessClients[]={"x.x.x.x"};'''. Multiple headless clients at different addresses can be added:
* If the Headless Client is running in the same network or the same computer, the server's config has to have the address in '''localClient[]=x.x.x.x'''.
<pre>
This will allow the server to communicate with the Headless Client using unrestricted bandwidth. It is also required to add the adress to '''headlessClients[]={"x.x.x.x"};'''.
Multiple headless clients at different addresses can be added:
<syntaxhighlight lang="cpp">
localClient[]={"127.0.0.1", "192.168.1.10", "192.168.1.210"};
localClient[]={"127.0.0.1", "192.168.1.10", "192.168.1.210"};
headlessClients[]={"127.0.0.1","192.168.1.10","192.168.1.210"};
headlessClients[]={"127.0.0.1","192.168.1.10","192.168.1.210"};
battleyeLicense=1;
battleyeLicense=1;
</pre>
</syntaxhighlight>
 
==== Headless Client on a Dedicated Server Notes ====


====Headless Client on a Dedicated Server Notes====
If the [[Arma 3 Headless Client]] and an [[Arma 3: Dedicated Server]] are running on the same Windows computer (VM or physical),
If the Arma 3 Headless Client and a Arma 3 Dedicated Server are running on the same Windows computer (VM or physical), it may be beneficial to set processor affinity to prevent execution intensive threads from being scheduled across the same (v)CPUs. The operating system will generally schedule threads efficiently, but manual CPU allocation is possible. This can be achieved by right-clicking on the process (e.g. Arma3Server.exe(*32)) in the '''processes tab''' of the Windows Task Manager and selecting '''Set Affinity...'''. Be aware that on a physical intel CPU, the odd numbered CPUs are Hyper-thread cores.
it may be beneficial to set processor affinity to prevent execution intensive threads from being scheduled across the same (v)CPUs.
The operating system will generally schedule threads efficiently, but manual CPU allocation is possible.
This can be achieved by right-clicking on the process (e.g. Arma3Server.exe(*32)) in the '''processes tab''' of the Windows Task Manager and selecting '''Set Affinity...'''.
Be aware that on a physical intel CPU, the odd numbered CPUs are Hyper-thread cores.


Note: You can use automated solution for affinity assign via batch file with commandline ''CMD /AFFINITY HEXvalue'' e.g. '''CMD /C START /AFFINITY 0xF3 arma3server.exe'''
Note: You can use automated solution for affinity assign via batch file with commandline ''CMD /AFFINITY HEXvalue'' e.g. '''CMD /C START /AFFINITY 0xF3 arma3server.exe'''


It has been observed that although the ARMA server and client processes will kick off multiple threads, the bulk of processing is used up by only one or two threads. For example, spawning 50 AI units does not generate 50 threads. There is one thread in the process that handles all of the AI units, irrespective of how many have been spawned. In this way, the ARMA server and client processes do not make maximal use of the processing capability found in modern processors and so AI counts do not scale easily. As such, faster CPU core speed is king and offloading the AI to multiple headless clients on the same computer will probably produce the best possible results for complex missions involving many AI units (albeit an expensive way to get the results).
It has been observed that although the ARMA server and client processes will kick off multiple threads, the bulk of processing is used up by only one or two threads.
For example, spawning 50 AI units does not generate 50 threads.
There is one thread in the process that handles all of the AI units, irrespective of how many have been spawned.
In this way, the ARMA server and client processes do not make maximal use of the processing capability found in modern processors and so AI counts do not scale easily.
As such, faster CPU core speed is king and offloading the AI to multiple headless clients on the same computer will probably produce the best possible results for complex missions involving many AI units (albeit an expensive way to get the results).


Read complete and detailed HOW-TO guide on Headless Client : https://community.bistudio.com/wiki/Arma_3_Headless_Client
{{Feature | Informative | Read the complete and detailed HOW-TO guide on Headless Client : [[Arma 3 Headless Client]].}}-


===<span style="color:#B22222"><b>Example Files</b></span>===
=== <span style="color: #B22; font-weight: bold">Example Files</span> ===
 
==== Arma3server_steamcmd_example.cmd ====


====Arma3server_steamcmd_example.cmd====
* Standalone Server Package (no need for game ownership on STEAM account)
* Standalone Server Package (no need for game ownership on STEAM account)
* Note: you might be asked to authorize your STEAM account due to STEAMguard (check email)
* Note: you might be asked to authorize your STEAM account due to STEAMguard (check email)
Line 433: Line 540:
* Note: Arma 3 server data package needs to be in separate folder from Arma 3 client (so always use unique folder like "A3server" or "Arma3server") to avoid file conflicts
* Note: Arma 3 server data package needs to be in separate folder from Arma 3 client (so always use unique folder like "A3server" or "Arma3server") to avoid file conflicts
* Code:
* Code:
<pre>@echo off
<syntaxhighlight lang="batch">
@echo off
@rem http://media.steampowered.com/installer/steamcmd.zip
@rem http://media.steampowered.com/installer/steamcmd.zip
SETLOCAL ENABLEDELAYEDEXPANSION
SETLOCAL ENABLEDELAYEDEXPANSION


      :: DEFINE the following variables where applicable to your install
:: DEFINE the following variables where applicable to your install


    SET STEAMLOGIN=mylogin mypassword
SET STEAMLOGIN=mylogin mypassword
    SET A3serverBRANCH=233780 -beta
SET A3serverBRANCH=233780 -beta
        :: For stable use 233780 -beta
:: For stable use 233780 -beta
        :: For Dev use 233780 -beta development
:: For Dev use 233780 -beta development
                :: Note, the missing qotation marks, these need to be wrapped around the entire "+app_data......"
:: Note, the missing qoutation marks, these need to be wrapped around the entire "+app_data......"
                :: There is no DEV branch data yet for Arma 3 Dedicated Server package !!!
:: There is no DEV branch data yet for Arma 3 Dedicated Server package !!!


    SET A3serverPath=D:\Games\ArmA3\A3Master
SET A3serverPath=D:\Games\ArmA3\A3Master
        SET STEAMPATH=D:\Apps\Steam
SET STEAMPATH=D:\Apps\Steam


:: _________________________________________________________
::  


echo.
echo.
echo     You are about to update ArmA 3 server
echo You are about to update Arma 3 server
echo       Dir: %A3serverPath%
echo Dir: %A3serverPath%
echo       Branch: %A3serverBRANCH%
echo Branch: %A3serverBRANCH%
echo.
echo.
echo     Key "ENTER" to proceed
echo Key "ENTER" to proceed
pause
pause
%STEAMPATH%\steamcmd.exe +login %STEAMLOGIN% +force_install_dir %A3serverPath% +"app_update %A3serverBRANCH%" validate +quit
%STEAMPATH%\steamcmd.exe +force_install_dir %A3serverPath% +login %STEAMLOGIN% +"app_update %A3serverBRANCH%" validate +quit
echo .
echo.
echo     Your ArmA 3 server is now up to date
echo Your Arma 3 server is now up to date
echo     key "ENTER" to exit
echo Press "ENTER" to exit
pause
pause
</syntaxhighlight>


</pre>
==== CONFIG_server.cfg ====


====CONFIG_server.cfg====
<syntaxhighlight lang="cpp">
 
//
<pre>//
// server.cfg
// server.cfg
//
//
Line 475: Line 583:
// NOTE: More parameters and details are available at http://community.bistudio.com/wiki/server.cfg
// NOTE: More parameters and details are available at http://community.bistudio.com/wiki/server.cfg


// STEAM PORTS (not needed anymore, it's +1 +2 to gameport)
// STEAM PORTS (not needed anymore, it is +1 +2 to gameport)
// steamPort       = 8766;     // default 8766, needs to be unique if multiple serves on same box
// steamPort = 8766; // default 8766, needs to be unique if multiple servers are on the same box
// steamQueryPort = 27016;   // default 27016, needs to be unique if multiple servers on same box
// steamQueryPort = 27016; // default 27016, needs to be unique if multiple servers are on the same box


// GENERAL SETTINGS
// GENERAL SETTINGS
hostname       = "My Arma 3 Server";   // Name of the server displayed in the public server list
hostname = "My Arma 3 Server"; // Name of the server displayed in the public server list
//password     = "ServerPassword";     // Password required to join the server (remove // at start of line to enable)
//password = "ServerPassword"; // Password required to join the server (remove // at start of line to enable)
passwordAdmin = "AdminPassword";       // Password to login as admin. Open the chat and type: #login password
passwordAdmin = "AdminPassword"; // Password to login as admin. Open the chat and type: #login password
maxPlayers     = 40;   // Maximum amount of players, including headless clients. Anybody who joins the server is considered a player, regardless of their role or team.
maxPlayers = 40; // Maximum amount of players, including headless clients. Anybody who joins the server is considered a player, regardless of their role or team.
persistent     = 1;     // If set to 1, missions will continue to run after all players have disconnected; required if you want to use the -autoInit startup parameter
persistent = 1; // If set to 1, missions will continue to run after all players have disconnected; required if you want to use the -autoInit startup parameter


// VOICE CHAT
// VOICE CHAT
disableVoN       = 0;     // If set to 1, voice chat will be disabled
disableVoN = 0; // If set to 1, voice chat will be disabled
vonCodecQuality = 10;   // Supports range 1-30; 1-10 is 8kHz (narrowband), 11-20 is 16kHz (wideband), 21-30 is 32kHz (ultrawideband); higher = better sound quality, more bandwidth consumption
vonCodecQuality = 10; // Supports range 1-30, the higher the better sound quality, the more bandwidth consumption:
// 1-10 is 8kHz (narrowband)
// 11-20 is 16kHz (wideband)
// 21-30 is 32kHz (ultrawideband)


// VOTING
// VOTING
voteMissionPlayers = 1;       // Minimum number of players required before displaying the mission selection screen, if you have not already selected a mission in this config
voteMissionPlayers = 1; // Minimum number of players required before displaying the mission selection screen, if you have not already selected a mission in this config
voteThreshold       = 0.33;   // Percentage (0.00 to 1.00) of players needed to vote something into effect, for example an admin or a new mission. Set to 9999 to disable voting.
voteThreshold = 0.33; // Percentage (0.00 to 1.00) of players needed to vote something into effect, for example an admin or a new mission. Set to 9999 to disable voting.
allowedVoteCmds[] =           // Voting commands allowed to players
allowedVoteCmds[] = // Voting commands allowed to players
{
{
// {command, preinit, postinit, threshold} - specifying a threshold value will override "voteThreshold" for that command
// {command, preinit, postinit, threshold} - specifying a threshold value will override "voteThreshold" for that command
{"admin", false, false}, // vote admin
{"admin", false, false}, // vote admin
{"kick", false, true, 0.51}, // vote kick
{"kick", false, true, 0.51}, // vote kick
{"missions", false, false}, // mission change
{"missions", false, false}, // mission change
{"mission", false, false}, // mission selection
{"mission", false, false}, // mission selection
{"restart", false, false}, // mission restart
{"restart", false, false}, // mission restart
{"reassign", false, false} // mission restart with roles unassigned
{"reassign", false, false} // mission restart with roles unassigned
};
};


Line 510: Line 621:
{
{
"Welcome to My Arma 3 Server",
"Welcome to My Arma 3 Server",
"Teamspeak: ts.somewhere.com",
"Discord: discord.somewhere.com",
"TeamSpeak: ts.somewhere.com",
"Website: www.example.com"
"Website: www.example.com"
};
};
motdInterval = 5;   // Number of seconds between each message
motdInterval = 5; // Number of seconds between each message


// MISSIONS CYCLE
// MISSIONS CYCLE
Line 520: Line 632:
class Mission1
class Mission1
{
{
template = "MyMission.Altis"; // Filename of pbo in MPMissions folder
template = "MyMission.Altis"; // Filename of pbo in MPMissions folder
difficulty = "Regular"; // "Recruit", "Regular", "Veteran", "Custom"
difficulty = "Regular"; // "Recruit", "Regular", "Veteran", "Custom"
};
};
};
};


// LOGGING
// LOGGING
timeStampFormat = "short";                 // Timestamp format used in the server RPT logs. Possible values are "none" (default), "short", "full"
timeStampFormat = "short"; // Timestamp format used in the server RPT logs. Possible values are "none" (default), "short", "full"
logFile         = "server_console.log";   // Server console output filename
logFile = "server_console.log"; // Server console output filename


// SECURITY
// SECURITY
BattlEye             = 1;   // If set to 1, BattlEye Anti-Cheat will be enabled on the server (default: 1, recommended: 1)
BattlEye = 1; // If set to 1, BattlEye Anti-Cheat will be enabled on the server (default: 1, recommended: 1)
verifySignatures     = 2;   // If set to 2, players with unknown or unsigned mods won't be allowed join (default: 0, recommended: 2)
verifySignatures = 2; // If set to 2, players with unknown or unsigned mods won't be allowed join (default: 0, recommended: 2)
kickDuplicate       = 1;   // If set to 1, players with an ID that is identical to another player will be kicked (recommended: 1)
kickDuplicate = 1; // If set to 1, players with an ID that is identical to another player will be kicked (recommended: 1)
allowedFilePatching = 1;   // Prevents clients with filePatching enabled from joining the server (0 = block filePatching, 1 = allow headless clients, 2 = allow all) (default: 0, recommended: 1)
allowedFilePatching = 1; // Prevents clients with filePatching enabled from joining the server
// (0 = block filePatching, 1 = allow headless clients, 2 = allow all) (default: 0, recommended: 1)


// FILE EXTENSIONS
// FILE EXTENSIONS
allowedLoadFileExtensions[] =       {"hpp","sqs","sqf","fsm","cpp","paa","txt","xml","inc","ext","sqm","ods","fxy","lip","csv","kb","bik","bikb","html","htm","biedi"}; // only allow files with those extensions to be loaded via loadFile command (since Arma 3 v1.19.124216)  
 
allowedPreprocessFileExtensions[] = {"hpp","sqs","sqf","fsm","cpp","paa","txt","xml","inc","ext","sqm","ods","fxy","lip","csv","kb","bik","bikb","html","htm","biedi"}; // only allow files with those extensions to be loaded via preprocessFile / preprocessFileLineNumbers commands (since Arma 3 v1.19.124323)
// only allow files with those extensions to be loaded via loadFile command (since Arma 3 v1.20)
allowedHTMLLoadExtensions[] =       {"htm","html","php","xml","txt"}; // only allow files and URLs with those extensions to be loaded via htmlLoad command (since Arma 3 v1.27.126715)
allowedLoadFileExtensions[] = {"hpp","sqs","sqf","fsm","cpp","paa","txt","xml","inc","ext","sqm","ods","fxy","lip","csv","kb","bik","bikb","html","htm","biedi"};
 
// only allow files with those extensions to be loaded via preprocessFile / preprocessFileLineNumbers commands (since Arma 3 v1.20)
allowedPreprocessFileExtensions[] = {"hpp","sqs","sqf","fsm","cpp","paa","txt","xml","inc","ext","sqm","ods","fxy","lip","csv","kb","bik","bikb","html","htm","biedi"};
 
// only allow files and URLs with those extensions to be loaded via htmlLoad command (since Arma 3 v1.28)
allowedHTMLLoadExtensions[] = {"htm","html","php","xml","txt"};


// EVENT SCRIPTS - see http://community.bistudio.com/wiki/ArmA:_Server_Side_Scripting
// EVENT SCRIPTS - see http://community.bistudio.com/wiki/ArmA:_Server_Side_Scripting
onUserConnected     = "";   // command to run when a player connects
onUserConnected = ""; // command to run when a player connects
onUserDisconnected = "";   // command to run when a player disconnects
onUserDisconnected = ""; // command to run when a player disconnects
doubleIdDetected   = "";   // command to run if a player has the same ID as another player in the server
doubleIdDetected = ""; // command to run if a player has the same ID as another player in the server
onUnsignedData     = "kick (_this select 0)";   // command to run if a player has unsigned files
onUnsignedData = "kick (_this select 0)"; // command to run if a player has unsigned files
onHackedData       = "kick (_this select 0)";   // command to run if a player has tampered files
onHackedData = "kick (_this select 0)"; // command to run if a player has tampered files


// HEADLESS CLIENT
// HEADLESS CLIENT
headlessClients[] = {"127.0.0.1"};   // list of IP addresses allowed to connect using headless clients; example: {"127.0.0.1", "192.168.1.100"};
headlessClients[] = {"127.0.0.1"}; // list of IP addresses allowed to connect using headless clients; example: {"127.0.0.1", "192.168.1.100"};
localClient[]     = {"127.0.0.1"};   // list of IP addresses to which are granted unlimited bandwidth; example: {"127.0.0.1", "192.168.1.100"};
localClient[] = {"127.0.0.1"}; // list of IP addresses to which are granted unlimited bandwidth; example: {"127.0.0.1", "192.168.1.100"};
</pre>
</syntaxhighlight>


====****.Arma3Profile====
==== server.Arma3Profile ====
 
<pre>version=2;
 
viewDistance=3000;
preferredObjectViewDistance=3000;
terrainGrid=12.5;
activeKeys[]=
{
};


See [[server.armaprofile]].


class Difficulties
==== Arma3.cfg ====
{
    class recruit
    {
        class Flags
        {
            Armor=1;
            FriendlyTag=0;
            EnemyTag=0;
            MineTag=1;
            HUD=1;
            HUDPerm=1;
            HUDWp=1;
            HUDWpPerm=1;
            HUDGroupInfo=1;
            AutoSpot=1;
            Map=1;
            WeaponCursor=1;
            AutoGuideAT=1;
            ClockIndicator=1;
            3rdPersonView=1;
            UltraAI=0;
            CameraShake=0;
            UnlimitedSaves=1;
            DeathMessages=1;
            NetStats=1;
            VonID=1;
            ExtendetInfoType=1;
        };
        skillFriendly=0.6;
        skillEnemy=0.6;
        precisionFriendly=0.28;
        precisionEnemy=0.28;
    };
    class regular
    {
        class Flags
        {
            Armor=1;
            FriendlyTag=1;
            EnemyTag=0;
            MineTag=1;
            HUD=1;
            HUDPerm=1;
            HUDWp=1;
            HUDWpPerm=1;
            HUDGroupInfo=1;
            AutoSpot=1;
            Map=1;
            WeaponCursor=1;
            AutoGuideAT=1;
            ClockIndicator=1;
            3rdPersonView=1;
            UltraAI=0;
            CameraShake=1;
            UnlimitedSaves=1;
            DeathMessages=1;
            NetStats=1;
            VonID=1;
            ExtendetInfoType=1;
        };
        skillFriendly=0.6;
        skillEnemy=0.6;
        precisionFriendly=0.28;
        precisionEnemy=0.28;
    };
    class veteran
    {
        class Flags
        {
            Armor=0;
            FriendlyTag=0;
            EnemyTag=0;
            MineTag=1;
            HUD=1;
            HUDWp=1;
            HUDWpPerm=1;
            HUDGroupInfo=1;
            AutoSpot=0;
            WeaponCursor=0;
            ClockIndicator=1;
            3rdPersonView=1;
            UltraAI=0;
            CameraShake=0;
            DeathMessages=0;
            NetStats=1;
            VonID=1;
            ExtendetInfoType=0;
        };
        skillFriendly=0.6;
        skillEnemy=0.6;
        precisionFriendly=0.28;
        precisionEnemy=0.28;
    };
    class mercenary
    {
        class Flags
        {
            HUD=1;
            AutoSpot=0;
            WeaponCursor=0;
            DeathMessages=0;
            NetStats=1;
            VonID=1;
        };
        skillFriendly=0.6;
        skillEnemy=0.6;
        precisionFriendly=0.28;
        precisionEnemy=0.28;
    };
};


difficulty="veteran";</pre>
{{Feature | Informative | See [[basic.cfg]] for more information.}}


====Arma3.cfg====
<syntaxhighlight lang="cpp">
See [[basic.cfg]] for more infos
language="English";
<pre>language="English";
adapter=-1;
adapter=-1;
MinBandwidth=800000;
MinBandwidth=800000;
Line 693: Line 693:
serverLatitude=52;
serverLatitude=52;
serverLongitudeAuto=0;
serverLongitudeAuto=0;
serverLatitudeAuto=52;</pre>
serverLatitudeAuto=52;
</syntaxhighlight>
 


==<span style="color:#0000ff"><b>Support &amp; Troubleshooting</b></span>==
== <span style="color: #33D; font-weight: bold">Support &amp; Troubleshooting</span> ==


===<span style="color:#B22222"><b>Known Issues</b></span>===
=== <span style="color: #B22; font-weight: bold">Known Issues</span> ===


# My server has 2500ms ping in server browser (This is caused by running the steam client as Non Administrator) see http://feedback.arma3.com/view.php?id=9374
# My server has 2500ms ping in server browser (This is caused by running the steam client as Non Administrator) see http://feedback.arma3.com/view.php?id=9374
# MaxMsgSend default is 128, higher values can create Desync problems if the server's available processing and/or bandwidth can not support the higher value
# MaxMsgSend default is 128, higher values can create Desync problems if the server's available processing and/or bandwidth can not support the higher value
# if you run Arma 3 Dedicated server data package on system where is also installed client there is possibility the server will load the full client data instead server data package, this is caused by precedence check in registry, the solution/workaround to this issue is to use arma3server.exe "-mod=" (where empty modline ensure it loads data from where server is placed)
# if you run Arma 3 Dedicated server data package on system where is also installed client there is possibility the server will load the full client data instead server data package,<!--
# upnp=1; //in server.cfg may result into server not starting for 600 seconds on server with active firewalls / anti-ddos measures , it's not recommended setting for dedicated-servers where server process related ports are open/forwarded by default
--> this is caused by precedence check in registry.<br>The solution/workaround to this issue is to use arma3server.exe {{hl|c= -mod=}} (where empty modline ensure it loads data from where server is placed)
 
# upnp=1; // in server.cfg may result into server not starting for 600 seconds on server with active firewalls / anti-ddos measures , <br>it's not recommended setting for dedicated-servers where server process related ports are open/forwarded by default
===<span style="color:#B22222"><b>Live Help</b></span>===
# using multiple server instances with too narrow ranges in between each (e.g. first 2302, second 2314) may cause problems with query where second server reports at first range,<!--
 
--> use of minimum +100 ports for next instance next to 2302 thus 2402 then 2502 etc. for utmost safety use +200 or +1000
For Live help, join the Skype group channel
# engine has legacy automated port increment system for occupied sockets (used for client-listen servers, upnp) where first is tried 2302, then +12 up to 15 times (so 2314, 2326 ... 2482)
Quote Originally Posted by Dwarden
all server hosters, we have Skype channel for collaborative work of server admins http://forums.bistudio.com/showthread.php?131825-Skype-groups-amp-other-contact-groups ... thanks
 
 
Or join the official Arma 3 Discord server!
https://discord.gg/arma


===<span style="color:#B22222"><b>F.A.Q</b></span>===
=== <span style="color: #B22; font-weight: bold">Live Help</span> ===
<span style="color:red"><b>WORK IN PROGRESS</b></span>


==See Also==
For live assistance, join the official Arma 3 Discord server! <big>https://discord.gg/arma</big>
Especially these channels:
* #server_admins
* #server_linux
* #server_windows
* #server_tools


[[ArmA: Server configuration|ArmA Server Configuration]]
=== <span style="color: #B22; font-weight: bold">F.A.Q</span> ===


[[Multiplayer_Server_Commands|Multiplayer Server Commands]]
{{Wiki|stub}}


[[Arma3:_Startup_Parameters#Server_Options|Server Options]]
== See Also ==


[[BattlEye#RCon|Battleye's RCON]]
* [[Arma3: Startup Parameters#Server Options|Server Options]]
* [[BattlEye#RCon|Battleye's RCON]]
* [[Arma 3 Headless Client]]
* [[Multiplayer Server Commands]]
* [[ArmA: Server configuration|ArmA Server Configuration]]


[[Arma_3_Headless_Client|Arma 3's Headless client]]


[[Category:ArmA:_Multiplayer|Dedicated Server]]
{{GameCategory|arma3|Tutorials}}
[[Category:Arma 2]]
{{GameCategory|arma3|Multiplayer}}
[[Category:Arma 3]]
[[Category:Arma 3: Tutorials]]
[[Category:Arma 3 Multiplayer]]

Latest revision as of 01:24, 2 February 2024

Arma 2: Operation Arrowhead
For previous titles see Arma Dedicated Server
Arma 3 logo black.png

Introduction

This page contains useful information on how to install and configure an ARMA 3 server and includes step by step guides of the install process. Also information on how to configure and run a server. The majority of directories and paths are customizable, however those defined are all consistent with the tutorial instructions.

Much of the tutorial here was created using this forum guide.

About steamCMD utility: if you are using it on a dedicated host to install and update Arma 3 dedicated server, it is a good practice to create a separate steam account for that. Arma 3 Dedicated server package is available for free (does not require regular Arma 3 to be purchased).


Installation

Requirements

  1. Steam Account
  2. Supported Operating System:
    • Windows Server 2008 or later
    • A modern Linux distribution
  3. Minimum Hardware:
source
Part Minimum Recommended
CPU 2.4 GHz Dual-Core 3.5 GHz Quad-Core
RAM 2GB 4GB
Storage 32 GB HDD 32 GB SSD
Arma 3 server does not support IPv6 or DSlite IPv4 via IPv6 tunnel. You must have a real IPv4 connection.
If you are in doubt, contact your Internet Service Provider.

Instructions (Windows o/s)

The following instructions will guide you through setting up one Arma 3 server on 1 box, however they will also set the foundations for installing multiple servers on that same box:

  1. Install the latest version of DirectX
  2. Create the following empty directories
    • D:\Apps\Steam
    • D:\Games\ArmA3\A3Master
    • D:\Games\ArmA3\A3Files
  3. Download steamcmd.exe and save it to your targetted Steam install directory (E.g D:\Apps\Steam)
  4. Run the steamcmd.exe. (This will download and install the required steam files to your custom steam directory)
  5. Create an #Arma3server_steamcmd_example.cmd file and save it to D:\Games\ArmA3\A3Files
  6. Run the #Arma3server_steamcmd_example.cmd file
  7. Just after logging into Steam, the console window will hang and ask for a validation key
    • Steam will have automatically sent you an email with this validation code, which you then need to input at the command prompt
    • The Update console window should then continue to run and install ArmA3 ((DEV or STABLE) version to the target directory as defined in the .cmd file) eg (D:\Games\ArmA3\A3Master)
  8. Create a shortcut for the ArmA3Server.exe on the server desktop
  9. Add the following parameters to the Target Line in the shortcut tab of the newly created desktop shortcut
    • -port=2302 (Required if running multiple server instances including any previous Arma 2 instances)
    • "-profiles=D:\Games\Arma3\A3Master"
    • -config=CONFIG_server.cfg
    • -world=empty
      • so it looks something similar to the following
      • "D:\Games\Arma3\A3Master\arma3server.exe" "-profiles=D:\Games\Arma3\A3Master" -port=2302 -config=CONFIG_server.cfg -world=empty
  10. Setup the #Port Forwarding in your firewall or\and router accordingly, also doesn't seems like implemented in some routers Port Trigger feature works with Arma 3 Server (tested with ASUS RT-N66U)
  11. Make sure you have:
    • Network Discovery enabled for your network type (the setting can be found in [Control Panel\Network and Internet\Network and Sharing Center\Advanced sharing settings]. If you have problem with its state reset on the interface reopen, check if all of the required for this feature services are running: DNS Client, Function Discovery Resource Publication, SSDP Discovery, UPnP Device Host; (makes server accessible from internet) (maybe it is about the services and not the network discovery)
    • Windows Media Player Network Sharing Service enabled (makes server joinable) ;

If you can't connect to server through server browser try to use "direct connect": this is a client side issue (doesn't mean other clients will have it too), reason for the issue for now unknown, I can say it is not related to: Windows services, Windows network settings, network routers, firewalls...

Device Host; (note: Changes to the above 2 settings require Arma relaunch to be applied, as for server same for client machines;)

Create a simple Notepad document called "CONFIG_server.cfg" and save it to the root folder of your ArmA3 install on the server D:\Games\ArmA3\A3Master
  1. Start up your shortcut, check the server runs. (You will see a console pop up in your desktop after a few seconds)
  2. Close the console window down, then you will need to edit the following files which will have been automatically created
    • D:\Games\Arma3\A3Master\Users\Adminstrator\Administrator.Arma3Profile
    • D:\Games\Arma3\A3Master\Users\Administrator\Arma3.cfg
  3. Restart the server
  4. Start up your client Arma3.exe (Running the same branch as the server, (eg Stable or DEV) and you should then be able to see your server in the server browser (Filters are available to reduce the server list)
  5. Login to your server using the password you defined in #CONFIG_server.cfg by typing "/" to open the chat window and then type (#login ADMINPASSWORD) followed by enter.
    Make sure to never forget the '#' in front of any server command!
  6. Once logged in you will be presented with a mission list, select one of the missions to start the game
  7. Prove the stability of your server by running BI missions initially before you start adding user made content

Instructions (Linux o/s)

Installation

As a security best practice, create a user to run steam instead of running as root or an administrator. This way, if your ArmA server is compromised the attacker will find it more difficult to access the rest of the operating system.

useradd -m -s /bin/bash steam

Switch to the newly created steam user.

sudo -i -u steam

Create a new directory for SteamCMD to avoid cluttering the home directory.

mkdir ~/steamcmd && cd ~/steamcmd

Download the SteamCMD for Linux tarball from the link at the Valve Developer Community page. Use a command line download tool such as wget or curl.

Extract the tarball.

tar xf steamcmd_linux.tar.gz

Execute steamcmd.sh. It will install the rest of the Steam client and start the Steam client shell. If this step fails on a 64-bit OS, you likely need to install 32-bit libraries.

./steamcmd.sh

Change the directory SteamCMD will install the server in.

force_install_dir ./arma3/

At the Steam client shell, login with a valid Steam username and password. The Valve Developer Community Wiki recommends that you create a new Steam account for this. SteamCMD will cache the login credentials and anyone who gains access to your server will be able to log into the account used here. In addition, you cannot log into a single Steam account from two places at once. You do not need to have Arma 3 purchased on the Steam account used here to download the server. Therefore, you should create a new Steam account with no purchases only for use on this server.

login myusername

Install the Arma 3 Linux dedicated server. The validate option will check for corruption.

app_update 233780 validate

Exit SteamCMD.

exit

Create the directories used to store the profile files and Arma3.cfg file.

mkdir -p ~/".local/share/Arma 3" && mkdir -p ~/".local/share/Arma 3 - Other Profiles"

Updating

You will have to update the server whenever a patch is released on Steam.

If the server is running, stop it by pressing Ctrl+C in the terminal (or screen/tmux instance) that the server is attached to. Otherwise, switch to the steam user.

sudo -u steam -i

Launch steamcmd.

cd /home/steam/steamcmd
./steamcmd.sh

Set the Arma 3 installation directory to the same directory used above.

force_install_dir ./arma3/

Login to the Steam account used in the installation section above.

login myusername

Update the Arma 3 Linux dedicated server. The validate option will check for corruption.

app_update 233780 validate

Exit SteamCMD.

exit

Configuration

You will most likely want to customize your server's name, password, security settings, and so on with a server.cfg file. Change to the arma3 directory and create and edit your server.cfg file.

cd ~/steamcmd/arma3
vim server.cfg

If you don't know how to use vim, use nano instead.

nano server.cfg

See server.cfg for documentation and examples.

The first time you run the server it will auto-create a profile file at ~/.local/share/Arma 3 - Other Profiles/server/server.Arma3Profile. Edit this file to customize difficulty settings.

The -profiles= parameter is broken on Linux - you must place your profiles in this directory.

Launching

A Linux executable is provided to launch the server. Make sure that you are running it under the steam user and not root or another administrator!

cd /home/steam/steamcmd/arma3
./arma3server_x64 -name=server -config=server.cfg

NB: If you are using the -mod= parameter, you must specify relative paths within or below the Arma 3 directory. Symlinks will work.

The arma3server_x64 process will attach to the current terminal. If you are connected to the server over SSH, the server will stop when you disconnect. You can keep the server running using a terminal multiplexeer like GNU Screen or tmux. There are many tutorials online on how to use these programs to detach and reattach processes from and to a terminal.

You can safely stop the server by pressing Ctrl+C in the terminal (or screen/tmux instance) that the server is attached to.

For older 32-bit executable use ./arma3server instead of ./arma3server_x64.

Case sensitivity & Mods

Some mods such as CUP Terrains and @ALiVE will not function if there are capital letters in any of their file names. If you do not update your mods on a regular basis, you can just use the command

find . -depth -exec rename 's/(.*)\/([^\/]*)/$1\/\L$2/' {} \;

in the directory where your mods are located. This will recursively search the directory tree and make all the filenames lowercase.

If you regularly update your mods using, e.g. ArmA3Sync, you will find that this will redownload any files/folders that have changed case every time you run it. The solution to this is to use a package called "ciopfs" - Case Insensitive On Purpose Filesystem. You should first run the "find . -depth..." command mentioned above on your mod folder. Then, make an empty directory outside of the mods directory, e.g. mods_caseinsensitive. You then mount the directory with:

ciopfs mods mods_caseinsensitive

and tell ArmA3Sync to synchronise in the mods_caseinsensitive directory. Once it has finished, you can unmount the directory with:

fusermount -u mods_caseinsensitive

You should find that all of the files in the original mods directory are lowercase.


Additional Info

Useful Links

Further Reading

Tools

Useful Addons

File Locations

Some files are automatically created when you use certain commandline parameters Some files have to be created manually. If you have followed the instructions accurately, you will now have the following files and directories in addition to the clean install

  • D:\Games\Arma3\A3Master\Users\Administrator\Administrator.Arma3Profile (Difficulty settings)
  • D:\Games\Arma3\A3Master\Users\Administrator\Administrator.vars.Arma3Profile (Some binarised content which you cannot edit)
  • D:\Games\Arma3\A3Master\Users\Administrator\Arma3.cfg (Bandwidth settings)
  • D:\Games\Arma3\A3Master\MPMissions\ (This is where custom made mission.pbo's need to be placed)
  • D:\Games\Arma3\A3Master\arma3.rpt (Debug Log, automatically created every time the arma3server.exe is started)
  • D:\Games\Arma3\A3Master\CONFIG_server.cfg (Manually created)
  • D:\Games\ArmA3\A3Files\Arma3server_steamcmd_example.cmd (Manually created)
  • D:\Apps\Steam\


Port Forwarding

Arma 3 uses the same default ports as Arma 2 with the addition of several ports. So if you intend running A2 and A3 servers on the same machine, you need to edit the ports used. Default ports are all UDP and as follows:

Incoming
  • 2302 (default Arma 3 Game port) + (VON is now part of main gameport due to NAT issues)
  • 2303 (STEAM query, +1)
  • 2304 (Steam port, +2)
  • 2305 (VON port, +3 - not used atm. but allocated)
  • 2306 (BattlEye traffic, +4)
Outgoing
DST Port Protocol Destination Comment
2344 TCP + UDP 81.0.236.111 BattlEye - arma31.battleye.com
2345 TCP 81.0.236.111 BattlEye - arma31.battleye.com
2302-2306 UDP any Arma Server to Client Traffic
2303 UDP any Arma Server STEAM query port
2304 UDP any Arma Server to STEAM master traffic



To define the ArmA3 Game port used, state -port= **** in your command line arguments (Where **** is the new initial Arma 3 Game, e.g 2302)

and to define your Steam ports add the following lines to your CONFIG_server.cfg (editing the actual port numbers as required)

STEAM ports are now linked to game-port as +1 for query and +2 to-master.

If you are running multiple servers, i would suggest the following format

SERVER 1


2302 UDP (gameport + VON)
2303 UDP (STEAM query port)
2304 UDP (STEAM master port)
2305 UDP (VON reserved port but not used atm.)
2306 UDP (BattlEye traffic port)
so open ports 2302-2306
... and leave at least 100 ports between the next 2nd server set

SERVER 2


2402 UDP (gameport + VON)
2403 UDP (STEAM query port)
2404 UDP (STEAM master port)
2405 UDP (VON reserved port but not used atm.)
2406 UDP (BattlEye traffic port)
so open ports 2402-2406
and leave at least 100 ports between the next 3rd server set, etc.

NAT traversal

UPnP allows you to automatically create port forwarding on your router to bypass NAT (UPnP enabled routers are required). The functionality can be easily enabled in server config as described in the server.cfg page.

Configuring for stable or Dev branch

Edit the Arma3server_steamcmd_example.cmd as defined below then run it

  • To select Development version
SET A3BRANCH=107410 -beta development
  • To select stable build (Dedicated server package)
SET A3BRANCH=233780 -beta
  • To select stable build (Full client\server package)
SET A3BRANCH=107410
Important Feature

Since 12th March 2013 the development branch and the stable branch versions are no longer compatible. This means:

  • Only DEV clients can connect to a DEV server
  • Only Stable clients can connect to stable servers

Advanced Configuration

Bandwidth Optimisation

Multiple Server configuration

There are various methods available to run multiple Dedicated Arma 3 servers on the same box. Each server instance requires:

  • Its own unique set of ports
  • Its own profile
  • Its own config

This post explains it more in depth.

Each method has some pro's and cons To select the preferred methodology that suits your requirements you need to have considered the following

  • The useage of the "Keys" folder
  • The useage of the "MpMissions" folder
  • Available Hard drive space
  • Update management

METHOD 1

see THIS POST for more detailed information This is copy of the master install into a different directory As may times as you have space for

Pros

  • Most robust
  • Unique MpMissions folder
  • Unique "keys" folder
  • Allows ability to run separate instances of different branches of the game, (E.g Dev or Stable)

Cons

  • Uses more drive space
  • Requires more effort to create and automate the updating process

METHOD 2

This uses 1 master install folder and has renamed arma3server.exe's in sub folders of the master see THIS POST for more detailed information

Pros (Compared to Method 1)

  • Uses less space than Method 1
  • Updating will be easier

Cons (Compared to Method 1)

  • Not very robust
  • Shares MPMissions folders with all the other exe's (Will create a very cluttered MpMissions folder and allows admins to select addon required missions for a mod this server instance isn't running
  • Shares "keys" folder with all other exe's (This can cause an issue when running various differing -mod servers)
  • Will not allow you to run separate instances of different branches of the game

METHOD 3

This is a hybrid of method 1, in that it is essentially a "Virtual" copy of the master install in a different directory the difference being that many folders are sim linked to the initial Master directory simlink GUI:

Pros (Compared to Method 1)

  • Uses less drive space (As you wont have multiple copies of the addons folder)
  • Allows for unique MpMissions folder if desired
  • Allows for unique "keys" folder if desired
  • Updating will be easier

Cons (Compared to Method 1)

  • Requires more effort to initially create the simlinks and directories
  • Will not allow you to run separate instances of different branches of the game at the same time, (E.g Dev or Stable)

For example, on Linux, if you initially have the following folder layout:

~/game_servers/

arma3server/ ... mods # folder where you keep your mods arma3server ...

Instead of copying the folders as directed in METHOD 1, run the following commands:

cd ~/game_servers/
mkdir arma3server_2/
ln -sr arma3server/* arma3server_2
cd arma3server_2
rm keys mpmissions mods
mkdir keys
mkdir mpmissions
mkdir mods

Then proceed with the rest of the instructions in METHOD 1.

METHOD 4

You can of course mix and match all 3 previous methods to suit your specific requirements.

Dedicated Server & Client configuration

In order for the Arma 3 server to be able to connect to the Steam servers, the Arma 3 server has to be ping-able (ICMP 8 - Echo Reply) as well as opened TCP/UDP ports.

The only known issue, is to make sure you start the server up before you start the steam client Failing to do this causes steam port issues and your client will not be able to connect to the server

Headless Client

See Arma 3 Headless Client for changes in headless clients.

A Headless Client can be used by missions to offload AI processing to a dedicated client, freeing up the dedicated server process from most AI processing. Thus more AI units can be spawned and the server process will be able to dedicate most of it is processing towards communication with the clients. For a Headless Client/Dedicated Server to function together efficiently, they both need to be connected to each other via extremely low latency and high bandwidth. Effectively, they need to be on the same LAN at least, but preferably running on the same computer.

Setup and Execution

  • Headless Client for ARMA 3 requires a valid active Steam account logged in to function (see Dwarden's post)
  • A Headless Client is simply Arma3.exe run from the command line with parameters, for example:
arma3.exe -connect=localhost -port=2444 -client -nosound -password=some_server_password -name=HC -profile=HC -mod=@CBA_A3;@blah;@blah;@blah

In the example above, the headless client is running on the same host as the dedicated server. It uses a profile called HC and connects to the server with a password as required by the server (the password is for password protected servers, optional). The server in this example is running on port 2444, alter this to the port of your server.

  • The Headless Client profile needs to be created like any other profile in Arma 3 (Note: It is best if you name this profile HC)

No configuration of the profile is necessary, but after creation, edit HC.Arma3Profile located in C:\Users\yourusername\Documents\Arma 3 - Other Profiles\HC and add this line:

battleyeLicense=1;

Alternatively, you can use the full Arma 3 client to connect to any multiplayer server with BattlEye enabled and accept the BattlEye License Agreement, which will do the same thing as manually editing HC.Arma3Profile.

Once the profile is ready, copy the profile directory to C:\Users\yourusername\Documents\Arma 3 - Other Profiles on the server (if the profile was not created on the server). If the profile was created on the server or is not going to run on the server and is already on the computer it is going to run on, then it is ready to go.

  • If the Headless Client is on the server, the server's cfg must have the local loopback address as seen below (e.g. A3Server.cfg):
localClient[]={"127.0.0.1"};
headlessClients[]={"127.0.0.1"};
battleyeLicense=1;

Dwarden suggests that battleyeLicense=1; be in the server's config, but it is unclear whether this is actually necessary. (Dwarden's post).

  • If the Headless Client is running in the same network or the same computer, the server's config has to have the address in localClient[]=x.x.x.x.

This will allow the server to communicate with the Headless Client using unrestricted bandwidth. It is also required to add the adress to headlessClients[]={"x.x.x.x"};. Multiple headless clients at different addresses can be added:

localClient[]={"127.0.0.1", "192.168.1.10", "192.168.1.210"};
headlessClients[]={"127.0.0.1","192.168.1.10","192.168.1.210"};
battleyeLicense=1;

Headless Client on a Dedicated Server Notes

If the Arma 3 Headless Client and an Arma 3: Dedicated Server are running on the same Windows computer (VM or physical), it may be beneficial to set processor affinity to prevent execution intensive threads from being scheduled across the same (v)CPUs. The operating system will generally schedule threads efficiently, but manual CPU allocation is possible. This can be achieved by right-clicking on the process (e.g. Arma3Server.exe(*32)) in the processes tab of the Windows Task Manager and selecting Set Affinity.... Be aware that on a physical intel CPU, the odd numbered CPUs are Hyper-thread cores.

Note: You can use automated solution for affinity assign via batch file with commandline CMD /AFFINITY HEXvalue e.g. CMD /C START /AFFINITY 0xF3 arma3server.exe

It has been observed that although the ARMA server and client processes will kick off multiple threads, the bulk of processing is used up by only one or two threads. For example, spawning 50 AI units does not generate 50 threads. There is one thread in the process that handles all of the AI units, irrespective of how many have been spawned. In this way, the ARMA server and client processes do not make maximal use of the processing capability found in modern processors and so AI counts do not scale easily. As such, faster CPU core speed is king and offloading the AI to multiple headless clients on the same computer will probably produce the best possible results for complex missions involving many AI units (albeit an expensive way to get the results).

Read the complete and detailed HOW-TO guide on Headless Client : Arma 3 Headless Client.

-

Example Files

Arma3server_steamcmd_example.cmd

  • Standalone Server Package (no need for game ownership on STEAM account)
  • Note: you might be asked to authorize your STEAM account due to STEAMguard (check email)
  • Note: it needs to be ran two or three times (1st authorize, 2nd STEAMcmd update itself, (when done, quit), 3rd update the Arma 3 Server data package)
  • Note: STEAMcmd needs to be in separate folder from STEAMclient (so always use unique folder like "STEAMcmd") to avoid file conflicts
  • Note: Arma 3 server data package needs to be in separate folder from Arma 3 client (so always use unique folder like "A3server" or "Arma3server") to avoid file conflicts
  • Code:
@echo off
@rem http://media.steampowered.com/installer/steamcmd.zip
SETLOCAL ENABLEDELAYEDEXPANSION

	:: DEFINE the following variables where applicable to your install

	SET STEAMLOGIN=mylogin mypassword
	SET A3serverBRANCH=233780 -beta
		:: For stable use 233780 -beta
		:: For Dev use 233780 -beta development
				:: Note, the missing qoutation marks, these need to be wrapped around the entire "+app_data......"
				:: There is no DEV branch data yet for Arma 3 Dedicated Server package !!!

	SET A3serverPath=D:\Games\ArmA3\A3Master
		SET STEAMPATH=D:\Apps\Steam

:: 

echo.
echo You are about to update Arma 3 server
echo 	Dir: %A3serverPath%
echo 	Branch: %A3serverBRANCH%
echo.
echo Key "ENTER" to proceed
pause
%STEAMPATH%\steamcmd.exe +force_install_dir %A3serverPath% +login %STEAMLOGIN% +"app_update %A3serverBRANCH%" validate +quit
echo.
echo Your Arma 3 server is now up to date
echo Press "ENTER" to exit
pause

CONFIG_server.cfg

//
// server.cfg
//
// comments are written with "//" in front of them.

// NOTE: More parameters and details are available at http://community.bistudio.com/wiki/server.cfg

// STEAM PORTS (not needed anymore, it is +1 +2 to gameport)
// steamPort		= 8766;		// default 8766, needs to be unique if multiple servers are on the same box
// steamQueryPort	= 27016;	// default 27016, needs to be unique if multiple servers are on the same box

// GENERAL SETTINGS
hostname		= "My Arma 3 Server";	// Name of the server displayed in the public server list
//password		= "ServerPassword";		// Password required to join the server (remove // at start of line to enable)
passwordAdmin	= "AdminPassword";		// Password to login as admin. Open the chat and type: #login password
maxPlayers		= 40;	// Maximum amount of players, including headless clients. Anybody who joins the server is considered a player, regardless of their role or team.
persistent		= 1;	// If set to 1, missions will continue to run after all players have disconnected; required if you want to use the -autoInit startup parameter

// VOICE CHAT
disableVoN		= 0;	// If set to 1, voice chat will be disabled
vonCodecQuality	= 10;	// Supports range 1-30, the higher the better sound quality, the more bandwidth consumption:
						// 1-10 is 8kHz (narrowband)
						// 11-20 is 16kHz (wideband)
						// 21-30 is 32kHz (ultrawideband)

// VOTING
voteMissionPlayers	= 1;		// Minimum number of players required before displaying the mission selection screen, if you have not already selected a mission in this config
voteThreshold		= 0.33;		// Percentage (0.00 to 1.00) of players needed to vote something into effect, for example an admin or a new mission. Set to 9999 to disable voting.
allowedVoteCmds[] =				// Voting commands allowed to players
{
	// {command, preinit, postinit, threshold} - specifying a threshold value will override "voteThreshold" for that command
	{"admin", false, false},		// vote admin
	{"kick", false, true, 0.51},	// vote kick
	{"missions", false, false},		// mission change
	{"mission", false, false},		// mission selection
	{"restart", false, false},		// mission restart
	{"reassign", false, false}		// mission restart with roles unassigned
};

// WELCOME MESSAGE ("message of the day")
// It can be several lines, separated by comma
// Empty messages "" will not be displayed, but can be used to increase the delay before other messages
motd[] =
{
	"Welcome to My Arma 3 Server",
	"Discord: discord.somewhere.com",
	"TeamSpeak: ts.somewhere.com",
	"Website: www.example.com"
};
motdInterval = 5;	// Number of seconds between each message

// MISSIONS CYCLE
class Missions
{
	class Mission1
	{
		template	= "MyMission.Altis";	// Filename of pbo in MPMissions folder
		difficulty	= "Regular";			// "Recruit", "Regular", "Veteran", "Custom"
	};
};

// LOGGING
timeStampFormat	= "short";				// Timestamp format used in the server RPT logs. Possible values are "none" (default), "short", "full"
logFile			= "server_console.log";	// Server console output filename

// SECURITY
BattlEye				= 1;	// If set to 1, BattlEye Anti-Cheat will be enabled on the server (default: 1, recommended: 1)
verifySignatures		= 2;	// If set to 2, players with unknown or unsigned mods won't be allowed join (default: 0, recommended: 2)
kickDuplicate			= 1;	// If set to 1, players with an ID that is identical to another player will be kicked (recommended: 1)
allowedFilePatching		= 1;	// Prevents clients with filePatching enabled from joining the server
								// (0 = block filePatching, 1 = allow headless clients, 2 = allow all) (default: 0, recommended: 1)

// FILE EXTENSIONS

// only allow files with those extensions to be loaded via loadFile command (since Arma 3 v1.20)
allowedLoadFileExtensions[] =		{"hpp","sqs","sqf","fsm","cpp","paa","txt","xml","inc","ext","sqm","ods","fxy","lip","csv","kb","bik","bikb","html","htm","biedi"};

// only allow files with those extensions to be loaded via preprocessFile / preprocessFileLineNumbers commands (since Arma 3 v1.20)
allowedPreprocessFileExtensions[] =	{"hpp","sqs","sqf","fsm","cpp","paa","txt","xml","inc","ext","sqm","ods","fxy","lip","csv","kb","bik","bikb","html","htm","biedi"};

// only allow files and URLs with those extensions to be loaded via htmlLoad command (since Arma 3 v1.28)
allowedHTMLLoadExtensions[] =		{"htm","html","php","xml","txt"};

// EVENT SCRIPTS - see http://community.bistudio.com/wiki/ArmA:_Server_Side_Scripting
onUserConnected		= "";	// command to run when a player connects
onUserDisconnected	= "";	// command to run when a player disconnects
doubleIdDetected	= "";	// command to run if a player has the same ID as another player in the server
onUnsignedData		= "kick (_this select 0)";	// command to run if a player has unsigned files
onHackedData		= "kick (_this select 0)";	// command to run if a player has tampered files

// HEADLESS CLIENT
headlessClients[]	= {"127.0.0.1"};	// list of IP addresses allowed to connect using headless clients; example: {"127.0.0.1", "192.168.1.100"};
localClient[]		= {"127.0.0.1"};	// list of IP addresses to which are granted unlimited bandwidth; example: {"127.0.0.1", "192.168.1.100"};

server.Arma3Profile

See server.armaprofile.

Arma3.cfg

See basic.cfg for more information.
language="English";
adapter=-1;
MinBandwidth=800000;
MaxBandwidth=25000000;
MaxMsgSend=384;
MaxSizeGuaranteed=512;
MaxSizeNonguaranteed=256;
MinErrorToSend=0.003;
MaxCustomFileSize=100000;
Windowed=0;
serverLongitude=0;
serverLatitude=52;
serverLongitudeAuto=0;
serverLatitudeAuto=52;


Support & Troubleshooting

Known Issues

  1. My server has 2500ms ping in server browser (This is caused by running the steam client as Non Administrator) see http://feedback.arma3.com/view.php?id=9374
  2. MaxMsgSend default is 128, higher values can create Desync problems if the server's available processing and/or bandwidth can not support the higher value
  3. if you run Arma 3 Dedicated server data package on system where is also installed client there is possibility the server will load the full client data instead server data package, this is caused by precedence check in registry.
    The solution/workaround to this issue is to use arma3server.exe -mod= (where empty modline ensure it loads data from where server is placed)
  4. upnp=1; // in server.cfg may result into server not starting for 600 seconds on server with active firewalls / anti-ddos measures ,
    it's not recommended setting for dedicated-servers where server process related ports are open/forwarded by default
  5. using multiple server instances with too narrow ranges in between each (e.g. first 2302, second 2314) may cause problems with query where second server reports at first range, use of minimum +100 ports for next instance next to 2302 thus 2402 then 2502 etc. for utmost safety use +200 or +1000
  6. engine has legacy automated port increment system for occupied sockets (used for client-listen servers, upnp) where first is tried 2302, then +12 up to 15 times (so 2314, 2326 ... 2482)

Live Help

For live assistance, join the official Arma 3 Discord server! https://discord.gg/arma Especially these channels:

  • #server_admins
  • #server_linux
  • #server_windows
  • #server_tools

F.A.Q

See Also