[ZBXNEXT-473] Ability to Check Now a specific passive item Created: 2010 Aug 17 Updated: 2024 Mar 04 Resolved: 2024 Mar 04 |
|
Status: | Closed |
Project: | ZABBIX FEATURE REQUESTS |
Component/s: | Frontend (F), Server (S) |
Affects Version/s: | None |
Fix Version/s: | None |
Type: | New Feature Request | Priority: | Major |
Reporter: | Robert Hau | Assignee: | Unassigned |
Resolution: | Won't fix | Votes: | 248 |
Labels: | items, pollers, sampling | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | Not Specified | ||
Original Estimate: | Not Specified | ||
Environment: |
Any |
Attachments: | Selection_097.png | ||||||||||||||||||||||||||||||||||||||||||||
Issue Links: |
|
Description |
I would like the ability to "Check Now" I have some triggers that have data only checked every few hours. I would be nice as an option to "Check Now" All of my data points. Specification: https://www.zabbix.org/wiki/Docs/specs/ZBXNEXT-473 |
Comments |
Comment by richlv [ 2010 Aug 18 ] |
items, not triggers, i suppose ? |
Comment by Robert Hau [ 2010 Sep 18 ] |
Items is correct. I am happy if we can setup even a script option that could force a refresh of all items on that host. |
Comment by Christophe [ 2011 Mar 25 ] |
Seems to be like requests: |
Comment by richlv [ 2011 Apr 08 ] |
related to |
Comment by Markus Koller [ 2011 Jul 29 ] |
We recently upgraded from Zabbix 1.6 to 1.8, and noticed that this doesn't seem to be possible anymore. Previously we'd just call reset_items_nextcheck($triggerids) in our customized triggers.php, which would trigger an item update within the next 0-30 seconds or so. In 1.8 this function is gone, and recreating its functionality doesn't seem to affect anything. I also tried changing various fields in the DB directly, also without success. Until this feature is added to Zabbix, is there any way to force an item update through the DB or something? |
Comment by Brad Clarke [ 2011 Nov 04 ] |
Something like this would be an awesome feature to have. Periodic monitoring is great, but the monitoring Zabbix does is like a set of unit tests for a running environment. The ability to force all of the tests to run as a way to validate a major change to the environment or to check everything after recovering from an outage of some sort would add a lot of value. |
Comment by Steve mushero [ 2012 May 23 ] |
We run servers all over the world and really need this to check something we've just fixed or configured, network configured, etc. Especially for some things we only check each hour, etc. |
Comment by Mateusz Kwiatkowski [ 2012 Jun 06 ] |
Any progress on this? This is key feature for us. |
Comment by Sergey Serg [ 2012 Jun 21 ] |
For us too |
Comment by Strahinja Kustudic [ 2012 Oct 17 ] |
This would be a really useful feature to have. |
Comment by Damian Nowak [ 2012 Nov 08 ] |
Would love to have it. |
Comment by Stas Shaklein [ 2013 Feb 09 ] |
I think, I was able to make a patch for this issue. Zabbix version: 2.1.0 Espessialy thanks to volter ImplementationData for various item types is actually gathered and stored, using the regular server mechanisms. A new item status in the database indicates the server to poll data early for a particular item. No schema changes are necessary. The server runs a certain number of StartDBSyncers processes, as specified in the config file. They're looking at the database once every minute and synchronize the server's cache. I defined a new item status – ITEM_STATUS_CHECKNOW = 6, which signals, that an item should be checked as early as possible. Once a DBSyncer catches this status, it schedules this item's next_check at now()+1 seconds and changes the status back to 0 (ACTIVE). Limitations1) Doesn't work for trapping items (SNMP, Zabbix) and active agent items Changes to the frontendLatest dataTwo additional columns show the item's status and a "Force check" button for everybody with read access to the particular host, except guests. Since there's a certain risk involved in this feature, users are warned of the consequences by a JS pop-up. Clicking the "Force check" button puts the item in the force check status and refreshes the view to reflect that. Configuration/Hosts/ItemsOne additional column holds the "Force check" button. Forcing checks here gives you no warning. You're expected to know what you're doing. The behaviour is the same as on Latest data otherwise. Alternatively, you may use the checkboxes and drop-down menu at the button. The latter approach gives you a JS pop-up, alarming you about the potential risk involved in checking many items at once. Checking disabled items leaves them in enabled state afterwards. Discussion:This implementation is versatile, as it's capable of dealing with any polling-type item – not just agent items. It can therefore force simple checks, external checks, SSH, SNMP and others. Data is not just shown, like it would be the case with zabbix_get, but actually recorded. This can be beneficial, if a problem is already solved, but the respective item will only be polled in 24 hours. Forcing a check can recover that flawed trigger. In cases where Zabbix is the only source of data for its users, forcing a check gives them up to date information. The potential downside of this implementation is, that you may spring triggers by polling for data more often than expected. Imagine an item polled every 5 minutes and the following trigger belonging to it: {host:item.max(#3)}= 0. Given the normal interval, you'd expect the trigger to spring after around 15 minutes. Forcing checks may reduce that span. The audit log can help to unveil such cases. |
Comment by Oleksii Zagorskyi [ 2013 Feb 09 ] |
Nice solution, thanks !
It worth to mention that actually not every minute but every server's config parameter /CacheUpdateFrequency/ seconds.
I'm afraid it can be problem for frontend and server because new (additional) item status should be correctly processed in many places (server & frontend side).
hmm, I remember I once investigated the calculate_item_nextcheck() function and I'm not sure it will work as you described. I mean there should not be shifts for next checks after one forced shifted check. Here is my own internal notes to zabbix code about this, sorry that no comments: delay = current_delay; shift = (ITEM_TYPE_JMX == item_type ? interfaceid : itemid); nextcheck = delay * (int)(now / (time_t)delay) + (int)(shift % (zbx_uint64_t)delay); # 21600 * 1323910698/21600 + (25933 % 21600) = 1323911533 # 1323907200 + 4333 = 1323911533 # less on 3498 while (nextcheck <= now) nextcheck += delay; 32477:20111215:025818.679 In calculate_item_nextcheck() interfaceid:30292 itemid:25933 delay:21600 flex_intervals:'' now:1323910698 Thu Dec 15 2011 02:58:18 GMT+2 32477:20111215:025818.679 End of calculate_item_nextcheck() nextcheck:1323911533 delay:21600 Thu Dec 15 2011 03:12:13 GMT+2 I know this feature request already long time and had my own vision.
This scenario looks to me more interesting zalex_ua Some details above seems will not be true FOR icmpping checks after |
Comment by Stas Shaklein [ 2013 Feb 09 ] |
You are right, but i tried to make minimal changes to the server's code and especially to working principle.
I have already made this changes
you are right. sorry.
I will try to make something like this zalex_ua thanks for your advice =] |
Comment by Oleksii Zagorskyi [ 2013 Feb 09 ] |
heh , usage of internal Jira syntax [~username] by community members leads to unexpected results - in the comment above it looks like a conversation between devs - looks like I wrote text "thanks for your advice =]", but actually Stas done that Probably write just text like "Oleksiy, thanks for your advice =]" would be cleaner |
Comment by Stefan [ 2013 Apr 19 ] |
i am not a programmer, but i has an idea, for this one we can use zabbix_get with a special option to insert the resul into the database.. now i want the actual data, the frontend run zabbix_get --insert-db $HOSTNAME -k $KEY |
Comment by richlv [ 2013 Dec 03 ] |
(1) considerations for final implementation : |
Comment by Chris Christensen [ 2014 Mar 24 ] |
There may be a way to accomplish the sentiment of this request (certainly what Sefan K. mentioned) with the zabbix_get tool / protocol: Ref: Docs/protocols/zabbix proxy/2.0 Preconditions:
$ zabbix_get -s server.name -p 10051 -k '{"request":"history data","host":"PROXYNAME","data":[{"host":"monitored.host.name","key":"system.hostname","clock":1395680522,"ns":236229445,"value":"Hello, World"}]}' { "response":"success", "info":"processed: 1; failed: 0; total: 1; seconds spent: 0.000045"}
(This is very similar to using the zabbix_sender tool with active items, but effectively emulating the data sender of the proxy.) |
Comment by Michal Humpula [ 2014 Oct 28 ] |
Ok, this is my try for passive check "check now" function: https://github.com/zabbix/zabbix/pull/1 Using trapper interface for passing request from PHP to zabbix server and simply updating the `nextcheck` to `now`. |
Comment by Jank Fane [ 2014 Nov 14 ] |
This is a very important feature for us. Note: we can currently perform instant check using Check_MK + Nagios or Shinken (just to mention a couple of them). |
Comment by Marc Schoechlin [ 2014 Dec 29 ] |
"Check now" should also available to active zabbix agent items. Zabbix agents should perform a blocking read on a tcp channel to get information which items should be delivered by "Check now" |
Comment by richlv [ 2014 Dec 29 ] |
active agent item forcing is ZBXNEXT-810 |
Comment by Adail Horst [ 2015 Feb 26 ] |
Hi All, In Zabbix-Extras we have this option in web interface |
Comment by Joan O'Callaghan [ 2015 Nov 16 ] |
Hi Adail, I do not see this option in the web interface with Zabbix Extras (ZE 2.1 with Zabbix 2.4) - how do you navigate to it? Do you have any screenshots of it? Regards, |
Comment by Adail Horst [ 2015 Nov 16 ] |
Hi Joan, Go to a ITEM definition of any HOST (not template... a host because need a interface to get the data ) and look at "Key line"... you have a extra button for this function |
Comment by viktorkho [ 2015 Dec 03 ] |
But "Latest data" page seems to be more suitable place for data requiring and receiving, isn't it? |
Comment by richlv [ 2016 Feb 15 ] |
note that this was voted by zabbix conference 2014 participants as the most needed feature and was supposed to be developed for zabbix 3.0 - but it turned out to be too complicated, thus it has not been implemented yet |
Comment by Adail Horst [ 2016 Feb 15 ] |
Ok, none vote on ZBX Conference... but ... 138 here... Currently I are making a new build of Zabbix-Extras... for Zabbix 3... I will still continue supporting this for Zabbix Agent (directly) requests. |
Comment by richlv [ 2016 Feb 15 ] |
no, this got the biggest amount of votes back then, but properly implementing the feature was too complicated, so it was not done - but let's move detailed discussions to irc |
Comment by Oleksii Zagorskyi [ 2016 Oct 05 ] |
far, but a bit related - |
Comment by Fab Lser [ 2017 May 09 ] |
Guys, I came from KS Advanded Host Monitor, and it has this feature from YEARS. Please add it, it's a MUST HAVE! |
Comment by Vucomir Ianculov [ 2017 Jun 21 ] |
I also miss this feature, Please add it. |
Comment by Marc [ 2017 Jun 21 ] |
vukomir, how about expressing your demand by considering (co-)sponsoring development |
Comment by Daniel Bossert [ 2017 Jul 25 ] |
Please add this feature? Many monitoring systems still has nagios and this is a feature where I am blamed when I have to tell zabbix doesn't have that feature. I just can't afford the spend money for the developers... |
Comment by finalbeta [ 2017 Aug 24 ] |
Zabbix 3.4 has added the ability to run remote commands over proxys. |
Comment by viktorkho [ 2018 Jan 04 ] |
One more question, plz. (3, on their own) |
Comment by richlv [ 2018 Jan 04 ] |
your new items would be polled any time between now() + server config cache update interval + item interval. i clearly recall a feature request to automatically poll new items sooner, but i cannot find it right now. edit : pidzero on irc found it - |
Comment by Marc [ 2018 Mar 16 ] |
|
Comment by Andris Zeila [ 2018 Mar 19 ] |
|
Comment by Mickael Martin (Cyres) [ 2020 Apr 15 ] |
Not similar to https://www.zabbix.com/documentation/4.0/manual/introduction/whatsnew400#retrieve_metrics_immediately ? |
Comment by Mickael Martin (Cyres) [ 2021 Jan 12 ] |
Can you close this request ? Similar to https://www.zabbix.com/documentation/4.0/manual/introduction/whatsnew400#retrieve_metrics_immediately for me. |
Comment by richlv [ 2021 Jan 12 ] |
Quoting Andris from his last comment:
|
Comment by Mickael Martin (Cyres) [ 2021 Jan 18 ] |
OK, I understand. Thank you very much for your return richlv |
Comment by Alexei Vladishev [ 2022 Jul 10 ] |
Zabbix 6.2 has introduced nearly instant update of Zabbix server configuration cache and also ability to "Check now" from the "Latest data" . I am ready to close this issue. Any objections? |
Comment by Marco Hofmann [ 2022 Jul 10 ] |
I agree. This is done. But may I shift your attention to ZBXNEXT-6169 to truly solve this request? |
Comment by Constantin Oshmyan [ 2022 Jul 11 ] |
alexei, it is very valuable part of functionality, thank you very much. (added) |
Comment by Mickael Martin (Cyres) [ 2023 Mar 13 ] |
Ok for me, alexei I wait update for ZBXNEXT-6169 as starko |
Comment by dimir [ 2024 Mar 04 ] |
Closing Won't fix based on comments above. Feel free to re-open if you disagree. |