[ZBX-21543] Not supported value - Preprocessing Step not working as expected Created: 2022 Aug 30 Updated: 2025 May 19 Resolved: 2025 May 19 |
|
Status: | Closed |
Project: | ZABBIX BUGS AND ISSUES |
Component/s: | Server (S) |
Affects Version/s: | 6.2.2 |
Fix Version/s: | 6.0.41rc1, 7.0.13rc1, 7.2.7rc1, 7.4.0rc1 |
Type: | Documentation task | Priority: | Major |
Reporter: | Dimitri Bellini | Assignee: | Arturs Dancis |
Resolution: | Fixed | Votes: | 3 |
Labels: | notsupported, preprocessing | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | 6.75h | ||
Original Estimate: | Not Specified | ||
Environment: |
RockyLinux 8.x |
Attachments: |
![]() ![]() ![]() |
Team: | |
Sprint: | S2401-2, DOC S25-W2/3 |
Story Points: | 1 |
Description |
Hi, Now using the zabbix trapper if I send only number everything is working as expected but if I send a "text" like this one: zabbix_sender -z 127.0.0.1 -s MyHost_byProxy -p 10151 -k my.trapper -o test I receive the error
, I supposed to check it using the preproc step and change the value to "999". Is something correct? As I remember it will work in the past |
Comments |
Comment by Dimitri Bellini [ 2022 Aug 30 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Ok I have tested also on Zabbix 6.0.x and it work in the same way of 6.2.2, text value are not managed by the step "Check of Not supported value". | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by Oleksii Zagorskyi [ 2022 Aug 30 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
I'd agree with issue reporter that from zabbix user point of view, the error is just about not supported, disregarding that it's classified on server side when processing real received value. CONFIRMED. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by Dimitri Bellini [ 2022 Aug 30 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Hi Oleksii, Thanks so much | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by dimir [ 2023 Jan 06 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
This is a very interesting one and let me try to clear up things here. How does Zabbix server processes the collected value
As you can see, 1.2 will never be caught by 2.1 and the item will become NOTSUPPORTED (the case of this issue). Some factsThe name of the Preprocessing step Check for not supported value is really confusing here and the biggest problem, as I see it. The idea of the name was "There was an issue while trying to retrieve the metric value". In your case, there was no issue when trying to collect it. In fact, with Trapper item this makes even less sense. There can never be an issue collecting a metric if it'a a Trapper item. If I could not collect it I have nothing to send. If it's not sent, we have nothing to do, if it is sent - we have the value, we had no issues retrieving it. If there is a network issue, it's a network issue, it's not related to the item. So, fact #1, the Check for not supported value preprocessing step does not make sense in Trapper item. I'd expect this choice not even available in the drop-down of the preprocessing steps if item type is Trapper. But then the issue would be when item type is changed, I mean, do we want to remember this step or not. I think at least for Trapper item there could be a red warning saying something like You have configured a preprocessing step that will be ignored so we won't have issues like this anymore and everyone would be happier. Fact #2, the preprocessing step name Check for not supported value is misleading as this step is not covering all the cases when item becomes NOTSUPPORTED (e. g. this issue). I'd suggest changing the name to something like Check if no item value could be retrieved. Then, when during troubleshooting a user would check preprocessing steps of a Trapper item it'd be easier to understand what's going on and why his step did not handle it. Fact #3, this should be documented, at least, as currently there is no word on the exceptions when this preprocessing step will not work. "Check for not supported value" VS item typeWhat about other item types? This is what I came up with after doing some investigation:
But! Remember that incorrect item value type received is not the case, it is never the case, because we have preprocessing steps that can be used to fix that. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by Dimitri Bellini [ 2023 Jan 09 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Dear Dimir, PS: I think we need this detailed explanation on Official Zabbix Documentation. Thanks | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by dimir [ 2023 Jan 09 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
I'd add Custom multiplier with parameter 1, checked the Custom on fail checkbox and either discard it or set the value to what's needed: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by Dimitri Bellini [ 2023 Jan 09 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Nice trick | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by dimir [ 2023 Jan 09 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
You cannot have failed "attempt to collect" with Trapper item. Value mismatch is not the issue of collecting, it's an issue of applying. This is why I believe changing that step name is so important. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by Dimitri Bellini [ 2023 Jan 10 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Sorry Dimir, my example is not related to Zabbix Trapper but for instance to SNMP Check.
Have you never seen such behavior? Best regards | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by dimir [ 2023 Jan 10 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
I understand but I'd still recommend to use Custom multiplier with 1. Let me try to explain. Besides other things Preprocessing is used to change the collected value type. And this is a valid use case. For example, we receive the temperature value as "15 ℃", which is, obviously, a string. We have the following item configuration:
After the value is preprocessed we will get an integer and there will be no value type error. Thus, since Preprocessing was introduced, no matter what item type, we cannot check the value type at the moment we receive it, because it might get fixed in Preprocessing steps. So, to conclude, if the reason of NOTSUPPORTED is incorrect value type (item type does not matter) it will always happen after Preprocessing, which means, this can never be caught with Check for not supported value. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by Dimitri Bellini [ 2023 Jan 11 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Ok, understood.
Thanks so much | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by dimir [ 2023 Jan 13 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
So, to conclude, here is what I suggest to do here:
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by dimir [ 2024 Nov 22 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Reopening as there was no changes in the code so the resolution "Fixed" is incorrect. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by dimir [ 2024 Nov 22 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
I propose to document how the "Check for not supported value" preprocessing step works. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by Dimitri Bellini [ 2024 Dec 06 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Hi Dimir, Rather than document it (which can be a good starting point), it might be more beneficial to enhance the feature to directly support these kinds of dynamic scenarios Thank you very much for your time and consideration. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by dimir [ 2024 Dec 11 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
For catching the "in-between steps" errors of this kind I believe there is "Custom on fail". I understand that there could be changes for good here but I can't decide on that. At this point we were allowed to document current behaviour. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by Dimitri Bellini [ 2024 Dec 11 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Hi Dimir, Thank you, it's the first step. Maybe ZabbixDevs can consider the suggestion for the next releases. Thank you! | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by dimir [ 2024 Dec 11 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
adancis Do you think we could have an appendix with a more detailed description for those that would like to dive deeper into this? An entry with the whole this comment: and a link to that from "Check for not supported value" step documentation with "learn more about"? While I agree this might be interesting for less than 1 % of our users I believe it might be crucial for those and isn't appendix exactly for things like this? | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by Arturs Dancis [ 2024 Dec 12 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Documentation updated:
For now, the documentation has been updated to include a clarification about the limit of the "Check for not supported value" preprocessing step. dimir, I'm uncertain whether adding a page to Appendixes is the best solution here; perhaps updating the Preprocessing details page would be more appropriate. I'll see what I can do. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by dimir [ 2024 Dec 13 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Thanks, adancis! That was some decent amount of work spent on this and I heard a couple of positive feedbacks about that very detailed description this is why I would hate loosing this information. And I mean, including that table with different item types. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment by Arturs Dancis [ 2025 May 15 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Documentation updated: |