[SERVER] Log file on Windows

Post your questions here
Post Reply
MxSimulatorMods
Crushed Dissenter
Posts: 62
Joined: Fri Aug 03, 2018 6:37 pm

[SERVER] Log file on Windows

Post by MxSimulatorMods »

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: 14928
Joined: Fri Nov 02, 2007 5:39 am
Team: No Frills Racing
Contact:

Re: [SERVER] Log file on Windows

Post by jlv »

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.
MxSimulatorMods
Crushed Dissenter
Posts: 62
Joined: Fri Aug 03, 2018 6:37 pm

Re: [SERVER] Log file on Windows

Post by MxSimulatorMods »

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: 14928
Joined: Fri Nov 02, 2007 5:39 am
Team: No Frills Racing
Contact:

Re: [SERVER] Log file on Windows

Post by jlv »

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.
Post Reply