Page 1 of 1

Can't Get Arma 3 Linux to generate RPT file

Posted: Tue Mar 28, 2017 4:55 pm
by canuckbrian
Hello,

I'm trying to finish my build on an Arma 3 template and I'm having a difficult time getting something to work.

By default the Linux Arma 3 binaries don't output an .RPT file (log file / console dump), but rather output errors to STDOUT and STDERR. You have to add something to the startup command line arguments so the server dumps the output to a log file.

Here's an example of a startup command for my server that I ran from the command line which works and logs the output to a date stamped file:

Code: Select all

./arma3server debug -server -enableHT -ip=216.19.188.183 -port=2302 -name=a3server_5 -cfg=basic.cfg -config=server.cfg -mod= -servermod= -world=empty -loadMissionToMemory -autoInit >>/ugcc/servers/3/5_arma3/logs/"arma3server_$(date +"%m-%d-%Y_%H-%M").rpt" 2>&1
Here's what my startup command looks like in UGCC:

Code: Select all

debug -server -enableHT -ip=%IP% -port=%Port% -name=a3server_%ServerID% -cfg=%Var3% -config=%Var4% -mod=%Var1% -servermod=%Var2% -world=empty -loadMissionToMemory -autoInit >>%Root%/logs/arma3server.rpt 2>&1
When I run it from UGCC using those parameters it starts the server but doesn't generate the log file.

Any reason you can think of as to why it's not dumping the console output to the log file when run from UGCC?

Re: Can't Get Arma 3 Linux to generate RPT file

Posted: Tue Mar 28, 2017 6:44 pm
by Masher
Stdout redirection does not work with the way the panel launches the server. You should use the -logfile argument to specify a log file to log to.

Re: Can't Get Arma 3 Linux to generate RPT file

Posted: Tue Mar 28, 2017 6:51 pm
by canuckbrian
Masher wrote:Stdout redirection does not work with the way the panel launches the server. You should use the -logfile argument to specify a log file to log to.
-logfile is not a valid arma3server command line parameter.

As per Bohemia Interactive:
It is not very well documented, but the Linux server outputs the "RPT log" messages on stdout/stderr. (The BIS Linux game servers have done this since back in the OFP days)

Solution: redirect stdout and stderr to a log file of your choosing. For example:

./arma3server -port=$port -pid=ServerRunning -cfg=basicServer.cpp -config=server.cpp "${mods}" >>log.${pid}.txt 2>&1

So: not a bug, but Linux dedis being "different". :-)