Ad Widget

Collapse

Excluding lines in log file monitoring.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • abel5405
    Member
    • Jan 2019
    • 47

    #1

    Excluding lines in log file monitoring.

    Greetings All,
    I apologies if this has been asked before but I could not find an answer in a forums search. I am using Zabbix to monitor the auth.log on my Linux box but I wold like to exclude any lines that has the word "cron" in it. Below is an example of the lines I wish to exclude from the log file monitoring. Any help would be greatly appreciated. Many thanks in advance for your help.
    Dec 20 05:35:01 zabbix CRON[30549]: pam_unix(cron:session): session closed for user root
  • gofree
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • Dec 2017
    • 400

    #2
    play with regexp - https://regex101.com/ - what you need is to write a regexp that excluded the cron word - basically agent will by default always go through all lines - but item patter should be created by regexp that is not looking for cron

    Comment

    • abel5405
      Member
      • Jan 2019
      • 47

      #3
      Thanks for the quick reply, got it working!

      Comment

      Working...