[ZBXNEXT-1521] allow wildcards (or macros) in aggregate items Created: 2012 Nov 19 Updated: 2021 May 22 Resolved: 2021 May 22 |
|
Status: | Closed |
Project: | ZABBIX FEATURE REQUESTS |
Component/s: | Server (S) |
Affects Version/s: | 2.0.3 |
Fix Version/s: | None |
Type: | New Feature Request | Priority: | Minor |
Reporter: | Samgarr | Assignee: | Unassigned |
Resolution: | Fixed | Votes: | 49 |
Labels: | aggregate, items, lld, regexps, wildcard | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | Not Specified | ||
Original Estimate: | Not Specified |
Issue Links: |
|
Description |
example: grpsum["somegroup","net.if.in[bond*,bytes]","last","0"] |
Comments |
Comment by richlv [ 2012 Nov 19 ] |
|
Comment by Oleksii Zagorskyi [ 2012 Nov 20 ] |
An alternative way - identically to currently supported an array for hostgroups implement support of such array for item key. Support of macros or wildcards here (for item key) look as different things. |
Comment by Justin McNutt [ 2013 Jun 27 ] |
I think a wildcard would work better, especially in cases like mine. The Items I want to aggregate are external checks. For each Host, one of the parameters sent to the external script changes. But otherwise, all of the keys in the Items are exactly the same. Example: SessionStats["byap", "10.5.3.23"] Only the IP address of the access point changes. I'd like to be able to create an aggregate Item with a key like one of these: Based on the Discovery rule: Wildcard parameter: "Raw" wildcard: In my case, an exception for aggregating external checks that would match against only the script name and ignore the parameters would work as well (perhaps as a checkbox in the configuration of the aggregate item?), but that may be too specific a case to write code for. A true wildcard would be far more flexible, if it's feasible. If wildcards create the potential for users to accidentally aggregate thousands of Items and destroy their systems, the Web UI could run a check when the user clicks Save. If the number of aggregated Items is more than 1000, a warning could pop up that asks the user to confirm the change. "The key you've entered will aggregate 13947810 Items. Are you sure you want to proceed? [ OK ] [ Back to Item Config ]" |
Comment by Justin McNutt [ 2013 Jun 27 ] |
If that's easy, great! I could put {HOST.IP1} in there and I'm done. If not, then we're back to wildcards. |
Comment by Oleksii Zagorskyi [ 2014 Jun 05 ] |
Something similar could be implemented for host groups, then it would resolve |
Comment by richlv [ 2014 Sep 10 ] |
|
Comment by Alex Bellia [ 2015 Mar 19 ] |
Just want to record my use case here in the hope it makes the issue clearer:- I have an external check which is called with a parameter set to {HOST.IP1}. So as seems logical there is a problem with evaluating {HOST.IP1} for an item which aggregates values from multiple hosts in a host group. Fixing this by allowing an array of values sounds problematic as each time I add a host to my host group I'd need to add another ip address In the meantime I will work around by turning the external check into a trapper item to get rid of {HOST.IP1}. glebs.ivanovskis I want to let you know that for such use case there is a solution - protect {HOST.IP} from resolving in aggregated item key by putting it into user macro. So, {$MACRO} => {HOST.IP} and your aggregated item looks like grpfunc[...,"item[{$MACRO}]",...]. aabell53 Thanks Glebs. I'll give this a go. |
Comment by richlv [ 2015 Aug 11 ] |
min/max etc for specific items is |
Comment by Jason Tucker [ 2016 Dec 15 ] |
Just wanted to add that my use case for this is basically the same as the one detailed by Justin previously. Currently, without the wildcard function for aggregate keys, I believe my only option is to create a calculated item first that includes all the keys I'm interested in, and then make an aggregate check of the calculated item. Being able to use a wildcard in the key would greatly streamline that process. |
Comment by Glebs Ivanovskis (Inactive) [ 2017 Mar 08 ] |
|
Comment by Kirill Varnakov [ 2018 May 07 ] |
+1000005000 |
Comment by Kirill Varnakov [ 2018 Nov 13 ] |
Please also add filter by Application. I use it to separate traffic on internal and external interfaces with custom LLD. |
Comment by Alexei Vladishev [ 2021 Mar 30 ] |
It will be implemented under |
Comment by Alexei Vladishev [ 2021 May 22 ] |
Implemented in Zabbix 5.4 under |