Hi,
Can anyone help me. I am trying to workout how to send an email when an error appears in the log file.
Router OS 3.17
Thanks Mark
:local loglist [/log find]
:local topics
:local thistopic "critical"
:foreach i in=$loglist do={
:set topics [/log get $i topics]
:if ([:len [:find $topics $thistopic]] > 0) do={
:put ([/log get $i time] . " " . [:tostr [/log get $i topics]] . " " . [/log get $i message])
}
}