Setup Server

Jawsh edited this page Oct 31, 2016 · 5 revisions

How to setup Altis Life server:

Here you'll learn how to setup your own server, in both windows and linux environments.

Before starting, you should have both life_server and Altis_Life.Altis packaged as a pbo.
You can find it already packaged in our releases tab, or you can pack it using pboManager.

Download extDB2 from here. It comes with both (Windows & Linux) versions.

Windows Server

Requirements:

Step 1: (Installing MySQL server)

  • Download MariaDB server, install it and take note of your root login and password.
  • Next, open HeidiSQL (Or MySQL WorkBench, or navicat... Heidi is already installed with MariaDB) and start a new session.
  • After starting the session, go to File > Load SQL File. Then, select the AltisLife.sql file. It'll open a new tab, then, just select the play button.
  • Now, refresh it and you'll see a new database in the left, with the name "AltisLife".

Step 2: (Installing Arma 3 Server)
This step is only needed if you don't have the ArmA 3 client already installed, if so, you can use its directory.

  • Extract steamcmd to the folder where you want your ArmA 3 server to be installed.
  • Now, double click on it, and it'll start to set the environment.
  • When it finishes, you'll see a white line starting with "Steam>" in the cmd.
  • Now do this:
Steam> login 'steamlogin' 'steampassword' 'steamguardcode'
Steam> app_update 233780 validate
Steam> quit

obs: steamguardcode is optional, and only for accounts with mobile guard enabled.
Example:

Steam> login armalife 123456 qtk4c
Steam> app_update 233780 validate
Steam> quit

Step 3: (Installing needed Mods/Mission)

  • After installing your ArmA 3 server, in the folder where you put steamcmd.exe, go: steamapps > common > Arma 3 Server
  • Afterwards, create a new folder with the name: @life_server, and inside this folder, another one with called: Addons
  • Now, go back to the ArmA 3 Server folder and create one more folder with named: @extDB2
  • It should be like this:
Arma 3 Server
├ @life_server
| └ Addons
└ @extDB2
  • After this, copy the life_server.pbo to @life_server > Addons folder and the Altis_Life.Altis.pbo to MPMissions folder.
  • And then, open extDB2-vXX.7z and extract @extDB2 and tbbmalloc.dll, in the Windows folder, to your ArmA 3 Server folder.
  • It should be like this:
Arma 3 Server
├ @life_server
| └ Addons
|   └ life_server.pbo
├ @extDB2
| ├ extdb-conf.ini
| └ extDB2.dll
├ MPMissions
| └ Altis_Life.Altis.pbo
└ tbbmalloc.dll

Step 4: (Configuring extDB)

  • Open the extdb-conf.ini file (inside the @extDB2 folder)
  • Inside it, edit this:
[MySQL_Example]
Type = MySQL
Name = Database_Name

Username = root
Password = password

IP = 127.0.0.1
Port = 3306

to this:

[altislife]
Type = MySQL
Name = altislife

Username = MyDatabaseLogin
Password = MyDatabasePassword

IP = MyDatabaseIP
Port = 3306

Example:

[altislife]
Type = MySQL
Name = altislife

Username = root
Password = 123456

IP = 127.0.0.1
Port = 3306

Obs: Use 127.0.0.1 as IP if the MySQL server shares the same machine with arma3server.

Step 5: (Starting server)

  • First, we need to create a batch file. For this, open the notepad, and paste this:
@echo off
echo ==============================
echo Starting the Altis Life Server
echo ==============================
echo.

set svExe=arma3server.exe
set svPort=2302
set svMod=@life_server;@extDB2;

IF not exist "basic.cfg" (
  echo ==============================
  echo    Creating basic.cfg file
  echo ==============================
  echo.

  echo MaxMsgSend = 128; >> basic.cfg
  echo MaxSizeGuaranteed = 512; >> basic.cfg
  echo MaxSizeNonguaranteed = 256; >> basic.cfg
  echo MinBandwidth = 131072; >> basic.cfg
  echo MaxBandwidth = 2097152000; >> basic.cfg
  echo MinErrorToSend = 0.001; >> basic.cfg
  echo MinErrorToSendNear = 0.01; >> basic.cfg
  echo MaxCustomFileSize = 1310720; >> basic.cfg
  echo class sockets{maxPacketSize = 1400;}; >> basic.cfg
  echo adapter=-1; >> basic.cfg
  echo 3D_Performance=1; >> basic.cfg
  echo Resolution_W=0; >> basic.cfg
  echo Resolution_H=0; >> basic.cfg
  echo Resolution_Bpp=32; >> basic.cfg
  echo terrainGrid=25; >> basic.cfg
  echo viewDistance=2000; >> basic.cfg
  echo Windowed=0; >> basic.cfg

  PING -n 2 127.0.0.1>nul
)

IF not exist "config.cfg" (
  echo ==============================
  echo    Creating config.cfg file
  echo ==============================
  echo.


  echo hostName = "ArmaLife Server -- Altis"; >> config.cfg
  echo password = ""; >> config.cfg
  echo passwordAdmin = "123456"; >> config.cfg
  echo serverCommandPassword = ""; >> config.cfg
  echo logFile = ""; >> config.cfg
  echo motd[] = { >> config.cfg
  echo }; >> config.cfg
  echo. >> config.cfg
  echo motdInterval = 3; >> config.cfg
  echo maxPlayers = 75; >> config.cfg
  echo kickduplicate = 1; >> config.cfg
  echo verifySignatures = 2; >> config.cfg
  echo allowedFilePatching = 0; >> config.cfg
  echo requiredSecureId = 0; >> config.cfg
  echo voteMissionPlayers = 3; >> config.cfg
  echo voteThreshold = 1.5; >> config.cfg
  echo disableVoN = 0; >> config.cfg
  echo vonCodecQuality = 10; >> config.cfg
  echo persistent = 1; >> config.cfg
  echo timeStampFormat = "none"; >> config.cfg
  echo BattlEye = 1; >> config.cfg
  echo. >> config.cfg
  echo doubleIdDetected = ""; >> config.cfg
  echo onUserConnected = ""; >> config.cfg
  echo onUserDisconnected = ""; >> config.cfg
  echo onHackedData = ""; >> config.cfg
  echo onDifferentData = ""; >> config.cfg
  echo onUnsignedData = ""; >> config.cfg
  echo regularCheck = ""; >> config.cfg
  echo. >> config.cfg
  echo class Missions >> config.cfg
  echo { >> config.cfg
  echo  class Mission_1 >> config.cfg
  echo  { >> config.cfg
  echo      template = "Altis_Life.Altis"; >> config.cfg
  echo      difficulty = "regular"; >> config.cfg
  echo  }; >> config.cfg
  echo }; >> config.cfg

  PING -n 2 127.0.0.1>nul
)

:folder
set Folder=ServerProfiles
IF not exist %Folder% (
  echo ==============================
  echo Creating ServerProfiles Folder
  echo ==============================
  echo.

  mkdir %Folder%

  PING -n 2 127.0.0.1>nul
)

echo ==============================
echo Server .exe: %svExe%
echo ==============================
echo.


start "" "%svExe%" -cfg=basic.cfg -config=config.cfg -profiles=ServerProfiles -nosound -port=%svPort% -serverMod=%svMod%;
PING -n 2 127.0.0.1>nul

echo ==============================
echo Listening to port: %svPort%
echo ==============================
echo.

PING -n 2 127.0.0.1>nul

echo ==============================
echo Mods: %svMod%
echo ==============================
echo.

PING -n 8 127.0.0.1>nul
@exit
  • Then, save it as startserver.bat and place it inside your ArmA 3 server folder
  • Now, just double click it and the server will start with all the needed mods & config files

Obs: Remember to install the vc2015 redist (x86) before starting the server. Otherwise, you won't be able to connect to the database.
Obs2: The batch creates both config & basic CFGs in the root folder. Obs3: The RPT logs from the server are saved in the ServerProfiles, inside your ArmA 3 server folder.

Linux Server

-=WIP=-