Ad Widget

Collapse

Problem Monitoring weekly log file

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • LEMORALES
    Junior Member
    • Sep 2014
    • 10

    #1

    Problem Monitoring weekly log file

    Hi community,

    I have this situation: I'm monitoring log files using item type log, and it have been running very well. Some of this log files are fed just once or twice a week. I have set these monitoring items with an interval of 60 seconds, in case that the log files could be fed at unexpected time.

    But when someone wants to check the latest data of the monitored log files, that data is not shown unless filter link is clicked and "show items without data" box is checked. Doing this, the item history for those items can be seen, and it can be seen properly and accurately, but the last check column only shows a -.

    What I want is to show all the items in latest data without have to check the "show items without data" box, and I can guess that this behavior could be produced by the current interval. Futhermore, I don“t want that the "last check" column for this log files in latest data, log files fed a couple of times a week as I told before, display a -. I want this column showing the last time that the searched string apears.

    If my desiree is not reachable using the item type log, how else could I monitor this log files?. Perhaps an obvious answer could be increase the interval, but, what about if the logs are fed at an unexpected time?. Also the item interval has an upper limit of 86400 (24 hours).

    Another solution that I could guess is to make a script in the monitored server and schedule it as a zabbix_sender object, but if I have not to add new stuff to the server, it would be better.

    Thanks a lot for taking the time to read my post, all the sugestions will be appreciated, and please apologize my english.

    Have a nice day!

    Luis Morales
    Last edited by LEMORALES; 28-09-2015, 15:40.
  • ingus.vilnis
    Senior Member
    Zabbix Certified Trainer
    Zabbix Certified SpecialistZabbix Certified Professional
    • Mar 2014
    • 908

    #2
    Hi Luis,

    You don't have to change the item update interval or other item settings. And zabbix_sender will not make any difference if the log is updated so seldom anyways.

    However there is one thing that you could try.

    Before changing anything you have to be aware that this change is global and may affect your server's performance if you have lots of such items or would try to display such data on large amount of hosts at a time on Latest data page.

    Find the directory where your Zabbix web interface files are stored. There go to file include/defines.inc.php.

    In this file find a setting
    Code:
    define('ZBX_HISTORY_PERIOD', 86400);
    This time period defines how old values will be displayed in Latest data and Overview pages.
    Try setting this value to a week (604800 seconds), save the file and check if that is what you need.

    Revert the setting if I did not get your request correctly.

    Best Regards,
    Ingus

    Comment

    • LEMORALES
      Junior Member
      • Sep 2014
      • 10

      #3
      Ingus, Hi

      Thanks a lot for your reply, and what a privilege. Sorry to feedback so delayed. I have applied your suggestion and it gave me what I wanted. And according with the size of my environment, it seems not to affect in a negative way my server's performance.

      Thanks a lot for the Solution.

      Luis Morales

      Comment

      Working...