LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Recommended watch tool (https://www.linuxquestions.org/questions/linux-software-2/recommended-watch-tool-4175601121/)

uihdff 03-05-2017 10:25 AM

Recommended watch tool
 
Platform: Asus RT-AC88U running Asuswrt-Rmerlin 380.65

I'm looking for a recommendation on a tool that can ...
  1. Scan log files and send an e-mail based on criteria. For example, errors / warnings, port scans, etc.
  2. Check the network connections on the router and send an e-mail when one of them isn't working.
I thought about using a cron job running grep and sendmail, but if there was one tool that could do all of the above, that would be preferable.

Turbocapitalist 03-05-2017 12:56 PM

Welcome.

That one tool would be called a shell script. You can have it use grep, awk, ping, traceroute, dig, and other utilities. It's easy enough and you'll get exactly the functions you need and the messages formatted exactly the way you want.

Habitual 03-05-2017 02:21 PM

snmp?

TB0ne 03-05-2017 03:40 PM

Quote:

Originally Posted by uihdff (Post 5679409)
Platform: Asus RT-AC88U running Asuswrt-Rmerlin 380.65
I'm looking for a recommendation on a tool that can ...
  1. Scan log files and send an e-mail based on criteria. For example, errors / warnings, port scans, etc.

Logwatch
Quote:

  1. Check the network connections on the router and send an e-mail when one of them isn't working.
I thought about using a cron job running grep and sendmail, but if there was one tool that could do all of the above, that would be preferable.
You don't define what you mean by "check the network connections on the router", so it's hard to say. If you mean a basic ping, a shell script is the way to go. If you mean check something more detailed, then SNMP (as Habitual suggested) would be good; scriptable along with snmpwalk too. Otherwise, if you want to check specific routes/traffic/ports/CPU and memory, etc., then who knows?

Habitual 03-05-2017 05:37 PM

logwatch! Of course.

I am not worthy. :)

uihdff 03-06-2017 06:52 AM

How would you install Logwatch on a platform like Asuswrt ?

So far I've only installed Entware-NG packages.


All times are GMT -5. The time now is 06:23 PM.