Logging or CLI client status
Hi,
I'm trialling Wg Server for Windows to replace my Softether OpenVPN setup.
I rely on log analysis to look at usage and who connected when.
Does the server keep logs anywhere? Or is there a CLI way of reporting the client status (connected/disconnected/source IP etc) so I can write a script to regularly check?
Thanks.
Hi @rdcuk, thanks for the question! WS4W is mostly a glorified wrapper around WireGuard. It does have a CLI, but that's mostly for running headless commands (for example, from Scheduled Tasks).
https://github.com/micahmo/WgServerforWindows?tab=readme-ov-file#cli
It doesn't really have any logging of its own. However, WireGuard has plenty of logging.
- You can run
wg showto print out the same thing that "View Status" shows in the WS4W UI. - You can supposedly run
wireguard /dumplog > logs.txtto view logs (seen here), but I couldn't get this to print anything for me. You can see the full logs in the WireGuard UI (open from the system tray) on the Logs tab.
I hope that helps a little!