windows_exporter
windows_exporter copied to clipboard
Feature Request: SMART-values
the SMART values should pr provided by WMI according to https://exchange.nagios.org/directory/Plugins/Operating-Systems/Windows/NRPE/check_smartwmi-SMART-Monitoring-for-Windows-by-using-builtin-WMI/details
that would be great!
This should be doable! Thanks for the suggestion.
I started work on this, but we need to resolve https://github.com/StackExchange/wmi/pull/30 before we can finish this off, the issue is the library we are using for talking WMI lacks the support for the data type used by the SMART data values.
I will push the initial work, but it will lack most of the functionality with regard to SMART values as compared to https://exchange.nagios.org/directory/Plugins/Operating-Systems/Windows/NRPE/check_smartwmi-SMART-Monitoring-for-Windows-by-using-builtin-WMI/details
Also, the WMI query seems to require admin rights, so you will need to configure the running account accordingly. You can test your permissions using this query:
gwmi -namespace root\wmi -class MSStorageDriver_ATAPISmartData
if it returns data, you should be able to use the "smart" collector of wmi_exporter. Otherwise you should get gwmi : Access denied
I tried to execute your test-query but even as local administrator I get the Access denied message. What additional privileges do I need to have to execute the query? How can these be added to the exporter service once it has the smart export feature enabled?
The pr in upstream StackExchange/wmi has been merged and vendor updated in https://github.com/martinlindhe/wmi_exporter/commit/df0db7a54f15d76e12840c9c6ac755748a64ae65#diff-9d82496a83fa4e47d10aefb501c99b4e
What's the status of this?
@johtso abandoned. You could resume work on https://github.com/prometheus-community/windows_exporter/pull/108
@martinlindhe thanks for clarifying! I think I'll see if I can get the data using the NewRelic PerfMon integration.. https://github.com/newrelic/nri-perfmon
I am no Windows expert, but I just found a little information about this.
Something like: Get-Disk | Get-StorageReliabilityCounter | Select-Object -Property "*" should get a list with items like:
ReadErrorsUncorrected : 0 WriteErrorsUncorrected : 0 ...
You wouldn't need anything like "add support for []uint8 slices" for that. The Node Exporter for Linux/Unix seems to export one metric per S.M.A.R.T. attribute found, so the Windows Exporter could just export one metric for ReadErrorsUncorrected, another one for WriteErrorsUncorrected, and so on.
There is also this flag, at least on modern versions of Windows:
(Get-WmiObject -Namespace root\wmi –Class MSStorageDriver_FailurePredictStatus).PredictFailure
I have read that this is a boolean flag. That could be exported as a separate metric too.
I don't know how much value would my comment add here. There is a project that can collect SMART data from windows, Scrutiny, which in reality uses smartmontools.
Yearly visit to pray for this.
This issue has been marked as stale because it has been open for 90 days with no activity. This thread will be automatically closed in 30 days if no further activity occurs.