Can anyone give me Netwatch UP and DOWN scripts to log client IP activity. So when client is pingable to get a log “Client connected at hh:mm“ and when client is not pingable to get a log “Client disconnected at hh:mm“.
Thanks
Can anyone give me Netwatch UP and DOWN scripts to log client IP activity. So when client is pingable to get a log “Client connected at hh:mm“ and when client is not pingable to get a log “Client disconnected at hh:mm“.
Thanks
And if client use firewall that block ping?
:log info "Client connected at $[/sys clock get time]"
You are absolutely right. And is there too complicated a script to do the same for wireguard clients? Like “Wireguard client connected at hh:mm“ and “Wireguard client disconnected at hh:mm“.
When you cannot modify the script above to say “Wireguard client” instead of “Client”, I’m afraid script writing (and RouterOS configuration) is not for you…
If you do not differentiate between configuration and management of computer networks (which includes knowledge of RouterOS) and writing scripts, perhaps you have no place on the forum to give unnecessarily stupid answers.
If you want to do professional work,
either take courses
https://mikrotik.com/training
or pay someone to do the work you need to do
https://mikrotik.com/consultants?category=consultants
Professional work coupled with free support between users often only creates friction,
Because often those who provide free assistance think
"but how can this professional, who is also paid, not know the basics of the products he uses?",
and if he points it out, he often receives rude responses.
Personally, I think professionally I would have sent the log output (which already exists) to an external syslog that would manage these logs as needed.
But that's another story.
Writing scripts for RouterOS is certainly not the basics of Mikrotik... I asked for information... everything is ok
if someone doesn't have a constructive opinion, he shouldn't waste space on the forum.
My advice still stands: send the logs that RouterOS already creates to an external syslog and analyze them from there...
Some answers seems to be stupid as some questions are stupid. That is life.
Use proper tools for the particular task.