in reply to Re^3: SMART info from drives in win32 using WMI
in thread SMART info from drives in win32 using WMI

Oops, I mistyped
MSStorageDriver_FailurePredictData
(wrote 'MMStorage...'). Anyway, the
$Drive->{'Status'}
post was an example of pulling data from one of the data structures. Note, however, that the query is on
Win32_DiskData
which doesn't contain SMART info. I've looked at a header file (wmidata.h) in the MS DDK and gleaned a couple of the properties that the data stucture should have (SelfTestStatus, TotalTime + others). However, I can't even get that to work. Perhaps this is too win32 specific, but I can't figure out where else to ask about it. Besides, I'd hoped somebody had a clever answer about figuring out which attributes could be found. Thanks for the help though. Dumper will probably come in handy later :-p
  • Comment on Re^4: SMART info from drives in win32 using WMI

Replies are listed 'Best First'.
Re^5: SMART info from drives in win32 using WMI ('fail')
by tye (Sage) on May 18, 2006 at 05:56 UTC

    The quoted documentation says (or at least implies) that it only sends SMART info if a "failure" is detected (and waiting for SMART to decide something has failed is what makes it mostly useless, as I recently noted).

    - tye        

      Sorry for the long post, but you're a little mistaken;
      actually, the SMART information on a disk contains certain threshold levels which predict whether a drive will fail. Of course this can't be determined with 100% certainty, but think of it more like "This drive will probably fail soon, so you should replace it."

      The thresholds are programmed into the drive's firmware, so it's easy to see if a threshold has been reached. Every hard drive gets errors during its lifespan, but a lot of them can be corrected by the drive itself using checksums, spare sectors etc. As a drive gets older or begins to fail the error rate will increase, and this is detectable by querying the SMART info. According to a website I read about it about 60% of all hard drive failures can be predicted this way - That's a lot better than not getting a warning at all.