Ad Widget

Collapse

Problem with log monitoring

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • kokox232
    Junior Member
    • Sep 2020
    • 13

    #1

    Problem with log monitoring

    Hello Guys,

    I have a problem with correct monitoring of log file. Prior I've created a zabbix alert about incoming new files into log folder. It works. I use vfs.file.time[/path/pathLOG_2020-09-25.txt,modify] with trigger "fuzzytime". But It doesn't resolve my problem, cause I have to monitor content, especially certain word "Error"
    I don't know how to do this. I was trying l
    logrt.count["/path/path/LOG_*.txt","Error"]

    What do you think? What is the problem?
  • GPegel
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • Dec 2015
    • 113

    #2
    I'm using this to see if the message "syserror" does appear in the log files:

    log[/log/app/node_name/error_log.log,"syserror","UTF-8",100]
    And that one works like a charm.

    Comment

    • kokox232
      Junior Member
      • Sep 2020
      • 13

      #3
      GPegel, thanks for answer!. Could you explain me what "UTF-8" and then "100" means? In my case is another problem, because every day log file is changed. Do you know how to fix it?

      Comment

      • Hamardaban
        Senior Member
        Zabbix Certified SpecialistZabbix Certified Professional
        • May 2019
        • 2713

        #4
        Sacral knowledge only for you :-)
        https://www.zabbix.com/documentation...rted_item_keys
        Look for
        log[file,<regexp>,<encoding>,<maxlines>,<mode>,<output >,<maxdelay>,<options>]
        log.count[file,<regexp>,<encoding>,<maxproclines>,<mode>,<ma xdelay>,<options>]

        Comment

        Working...