[SERVER] Log file on Windows

Post your questions here
User avatar
MxSimulatorMods
Posts: 52
Joined: Fri Aug 03, 2018 6:37 pm

[SERVER] Log file on Windows

Postby MxSimulatorMods » Wed Feb 06, 2019 11:00 am

Hi

I'm trying to add log file in my windows server.
I use this line to start my server : "mxserver --args-file serverargs.txt > log.txt" but nothing is writed in my log.txt
Image

jlv
Site Admin
Posts: 13126
Joined: Fri Nov 02, 2007 5:39 am
Team: No Frills Racing
Contact:

Re: [SERVER] Log file on Windows

Postby jlv » Thu Feb 07, 2019 3:28 am

You want to redirect stderr, so use 2>log.txt for the redirection.
Josh Vanderhoof
Sole Proprietor
jlv@mxsimulator.com
If you email, put "MX Simulator" in the subject to make sure it gets through my spam filter.

User avatar
MxSimulatorMods
Posts: 52
Joined: Fri Aug 03, 2018 6:37 pm

Re: [SERVER] Log file on Windows

Postby MxSimulatorMods » Thu Feb 07, 2019 12:45 pm

It's working but the log.Txt is updated only when I close my server :(
It's possible to make it in live ?
Image

jlv
Site Admin
Posts: 13126
Joined: Fri Nov 02, 2007 5:39 am
Team: No Frills Racing
Contact:

Re: [SERVER] Log file on Windows

Postby jlv » Fri Feb 08, 2019 2:36 am

Not sure about that. Windows must be buffering stderr when it's redirected to a file. Stuff like this is the reason why most people use Linux for their servers.
Josh Vanderhoof
Sole Proprietor
jlv@mxsimulator.com
If you email, put "MX Simulator" in the subject to make sure it gets through my spam filter.


Return to “Help / Troubleshooting”

Who is online

Users browsing this forum: No registered users and 2 guests