-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
0 value now returns 'None' #8
Comments
Resolved in latest update 0.1.3 with adding type hinting. |
I updated to the new script and the -type setting, however the result is still the same.
|
Finally got around to doing some more testing and found that the problem is only with the "get" action, but it's working correctly with the "json" and "both "actions:
So i ended up using json with the JSONPath preprocessor. However that preprocessor doesn't work with the [] brackets so i had to trim those first. Might be a seperate bug but unsure as this is the first time i worked with json data in zabbix. |
After my distro removed python 1 and 2 i found you had already updated your script to python3. However after switching over, and updating everything to use -cred, it now returns 'None' where it used to return '0'.
This generates zabbix errors like:
"item "SERVER:zbxwmi["-action","get","-item","3","-fields","PercentProcessorTime","Win32_PerfFormattedData_PerfOS_Processor","-cred","{$WMI_AUTHFILE}",{HOST.HOST}]" became not supported: Value of type "string" is not suitable for value type "Numeric (unsigned)". Value "None"
When it is able to read a real value it will become supported again and thus is constantly flip flopping.
If i change the type to text it won't flip flop but then graphs won't work.
On hosts with history using latest data with values there are no more 0's to be found in the history since the switch to the python3 script, while they do show before.
I tried setting the interval to 5m but that didn't change anything, but in history i can see 1m never was a problem before.
Nothing has changed on the windows machines.
The text was updated successfully, but these errors were encountered: