-
-
Notifications
You must be signed in to change notification settings - Fork 61
qts-disk-smart: Plugin not working since new update #696
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
Comments
|
|
It seems that the API URL and result structure have changed. |
I got the same issue and looked a bit into the source. I found out that the request has to be a get and not a post. ...
# get the values
url = '{}/cgi-bin/disk/qsmart.cgi?func=all_hd_data&sid={}'.format(args.URL, authSid)
result = lib.base.coe(lib.url.fetch(url, insecure=args.INSECURE, no_proxy=args.NO_PROXY, timeout=args.TIMEOUT))
data = xmltodict.parse(result)['QDocRoot']
... |
thanks a lot @FildCommander for the testing! please let me know if it works with this fix |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This issue respects the following points:
Which variant of the Monitoring Plugins do you use?
Bug description
The plugin worked great until the last Qnap Firmware update to firmware version: QTS 5.1.0.2466
Since then, I get the following error:
Traceback (most recent call last): File "/usr/lib/nagios/plugins/c_check_qts-disk-smart", line 181, in 'module' main() File "/usr/lib/nagios/plugins/c_check_qts-disk-smart", line 141, in main for disk in data["Disk_Info"]["entry"]: KeyError: 'Disk_Info'
Does anyone else get this error since the last firmware update, or does this just happen on mine?
I use some other qts-plugins from you guys, and the others still work as expected.
Steps to reproduce - Plugin call
'/usr/lib/nagios/plugins/qts-disk-smart' '--insecure' '--password' 'somepassword' '--url' 'https://url:4444' '--username' 'someusername'
Steps to reproduce - Data
No response
Environment
Linux hostname 5.10.0-23-amd64 #1 SMP Debian 5.10.179-2 (2023-07-14) x86_64 GNU/Linux
QNAP 673 with latest firmware.
Plugin Version
v2023071203
Python version
3.9.2
List of Python modules
No response
Additional Information
No response
The text was updated successfully, but these errors were encountered: