add doc/netwatch-syslog.md

This commit is contained in:
Christian Hesse 2020-03-27 21:49:03 +01:00
parent f482c565c7
commit 222fe8fd54
2 changed files with 35 additions and 0 deletions

34
doc/netwatch-syslog.md Normal file
View file

@ -0,0 +1,34 @@
Manage remote logging
=====================
[◀ Go back to main README](../README.md)
Description
-----------
RouterOS supports sending log messages via network to a remote syslog server.
If the server is not available no log messages (with potentially sensitive
information) should be sent. This script disables remote logging by
availability.
Requirements and installation
-----------------------------
Let's assume there is a remote log action and associated logging rule:
/ system logging action set remote=10.0.0.1 [ find where name="remote" ];
/ system logging add action=remote topics=info;
Just install the script:
$ScriptInstallUpdate netwatch-syslog;
... and create a netwatch matching the IP address from logging action above:
/ tool netwatch add down-script=netwatch-syslog host=10.0.0.1 up-script=netwatch-syslog;
All logging rules are disabled when host is down.
---
[◀ Go back to main README](../README.md)
[▲ Go back to top](#top)

View file

@ -5,6 +5,7 @@
# requires: dont-require-permissions=yes
#
# manage remote logging facilities
# https://git.eworm.de/cgit/routeros-scripts/about/doc/netwatch-syslog.md
:local Remote [ /system logging action get ([ find where target=remote ]->0) remote ];