[ZBXNEXT-3695] Allow Zabbix agent(active) to report metric to Server instant on value change (state change) Created: 2017 Feb 09  Updated: 2019 Mar 15  Resolved: 2019 Mar 15

Status: Closed
Project: ZABBIX FEATURE REQUESTS
Component/s: Agent (G)
Affects Version/s: 3.2.3
Fix Version/s: None

Type: Change Request Priority: Major
Reporter: Vitaly Zhuravlev Assignee: Unassigned
Resolution: Duplicate Votes: 3
Labels: activeagent, agent, state
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Causes
causes ZBXNEXT-4724 Advanced preprocessing: validation an... Closed

 Description   

My suggestion is to turn zabbix agent locally into state change machine.

Let's say you collect many many things that don't change very often like:

  • Serial numbers, hostname,MACs or other inventory information
  • Network Interfaces statuses, maximum bandwidth, descriptions, etc...
  • HDD SMART status OK or BAD
  • other stuff that either status of something (you put value maps very often on it) or descriptions.

So now you might have an issue with that, especially statuses:

  • You want to be notified as quickly as possible when status changes to something bad (like interface is down)
  • On the other hand:
  • you don't really want to fill in your Zabbix DB with interface statuses values every 10seconds
  • and don't want to create unnecessary load on trappers, network and other resources.

So here is my suggestion how to solve that by enhancing Zabbix agent(active):

  • Make Zabbix Agent to store last collected item value locally in memory.
    For items marked with a new tick in web interface like 'state monitor':
  • Keep checking this item every 5-30 seconds locally(or introduce another parameter in item configuration called 'Local update interval'):
    If new item value is different from the previous one stored in-memory then send this item immediatly to the Server. Otherwise just do nothing.
  • Send item value to Zabbix Server as mentioned in regular Update interval (lets say every 60, 30, 10 or 5 minutes) even if there was no state change. This will work as a proof that item is still alive.

What will you get?

  • Almost instant status update when something changes.
  • And you will get it without any pressure on Zabbix DB, zabbix-server or network

P.S.
This suggestion can be further expanded into SNMP or simple checks: pollers will check items marked as 'state monitor' flag as frequently as possible, but store values only on state change or when classic update interval comes



 Comments   
Comment by richlv [ 2017 Feb 09 ]

could this be a duplicate of ZBXNEXT-113 ?

Comment by Vitaly Zhuravlev [ 2017 Feb 09 ]

Partially. Couldn't find it through searching.

Key difference is that this suggests to send item value immediatly on state change

Comment by Glebs Ivanovskis (Inactive) [ 2017 Feb 09 ]

This request has a potential to grow into agent-based triggers.

Comment by Vitaly Zhuravlev [ 2019 Mar 15 ]

This feature is implemented as new preprocessing rules in Zabbix 4.2(available in beta) ( ZBNEXT-4724 throttling, throttling with heartbeat). Preprocessing on agents will be added later.

Generated at Sat Apr 20 08:59:12 EEST 2024 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.