| To: | "Frank Ch. Eigler" <fche@xxxxxxxxxx> |
|---|---|
| Subject: | Re: PMDAs for lm_sensors, HDD SMART monitoringâ |
| From: | "David O'Shea" <dcoshea@xxxxxxxxx> |
| Date: | Sun, 3 Jan 2016 20:45:57 +1030 |
| Cc: | pcp developers <pcp@xxxxxxxxxxx> |
| Delivered-to: | pcp@xxxxxxxxxxx |
| Dkim-signature: | v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=STJy81p6ny1SiCZZYbZchSCcoy7UfdrJqRL2JYKMn6s=; b=nucxsRXaNjbBUG9SXB/sqK8ScnJlfAwJMzmb/jePoWbiHlgoTCXbWsKaWoM112Eeiw /BrssJCGExgaNtCwy/1o8tWiaAund58funoNSehKV4AO2jYairZ/IbujSHichhD6VPUw WVrjNKSeE6CHyoGvSeXE02LmScvYq4lyuM3sD6SFbIiawuxhVraWTXS1bKB/bZ0z3KJ4 A2fuqMpt5xNIFvQaSl3rdPWEuoplTvIkICZMu/oVzpibaa3tcTf5TqYhi/0nNwMAEojj XMR7IariHjhMsUnMf+T2lOiAW+ewLDUCMKiWrMtv4Q+7OtgjGrRG07qq0/N00toz/FdW FPOA== |
| In-reply-to: | <20160102153416.GC13026@xxxxxxxxxx> |
| References: | <CAN0DjM1GGZJ2MOdDohbaf7WZ25j3g_7CxzfWxVvKH=a2pKcLAw@xxxxxxxxxxxxxx> <y0md1tpqmoe.fsf@xxxxxxxx> <CAN0DjM0VEmykF15F=ZfmRGjpog0knCyvnx_YrmuAik979huW5w@xxxxxxxxxxxxxx> <20160102153416.GC13026@xxxxxxxxxx> |
|
Hi Frank,
On Sun, Jan 3, 2016 at 2:04 AM, Frank Ch. Eigler <fche@xxxxxxxxxx> wrote: Hi, David - Will do.  For comparison, the pmdarpm collector thread also runs in the By "*notify events" you mean e.g. inotify, rather than any kind of PCP thing, right? Unfortunately I can't find any evidence of a scheme for finding out about changes in SMART attributes via notifications from the disk itself. Perhaps I could use some scheme like this to find out when disks are added to/removed from the system in order to avoid running 'smartctl --scan-open' all the time to detect that, but then I was hoping for this PMDA to be usable on Windows too.  For another comparison, pmdapapi starts collecting perfctr data only If I was to use such a scheme for SMART, I assume I'd still need to read attributes once at startup, and also whenever a new disk appears, since I need to be able to correctly report all the available metrics? That sounds a bit more complex. Also, wouldn't it be silly to install a PMDA you're never going to retrieve metrics from anyway? > [...] So, just to be clear, given that for example Something like: smart.attr.by_number.99 smart.attr.by_name.reallocated_sector_ct (ignoring how I'll deal with vendor-specific attributes for now)?
Yeah, I figured the other option is to use libatasmart, but that would make it harder to port to Windows, whereas I'm using pySMART to scrape the 'smartctl' output and it already claims to support Windows to some extent.  > My problem is giving them unique item numbers, which I don't think Oh I see, you're suggesting that if I see attribute 009 "Power_On_Minutes", I could look in this file and work out that these are all the unique names for attribute 009 in the order they appear in the file: (1) Power_On_Hours_and_Msec (2) Power_On_Hours (3) Proprietary_9 (4) Power_On_Seconds (5) Power_On_Minutes (6) Power_On_Half_Minutes (I hope that is the worst example :) ) so I can use ordinal 5 to make a unique number for the metric? This sounds good. A comment in the file says: Â* The table will be searched from the start to end or until the first match, Â* so the order in the table is important for distinct entries that could match Â* the same drive. so I guess we can't hope that new entries are always added at the end of the file, but hopefully in general the opportunities for ambiguity - where the order really matters - are only between drives from the same manufacturer, so in general this scheme would generate stable metric numbers. I note that I just found that the 'smartctl --presets=showall' command gives a dump of this information which is a lot easier to parse, and which is based on not just /usr/share/smartmontools/drivedb.h but also /etc/smartmontools/smart_drivedb.h (or some alternative file(s) as specified on the command line). I take it that this solution, whilst not guaranteeing that metric numbers will be stable forever, is probably good enough? > [...] Thanks! I gather that sometimes people aren't happy about bugs filed against RHEL that have only been found in CentOS, but I'll give it a try. Regards, David |
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | EL6 repo missing pcp-pmda-infiniband and bintray issues, Trey Dockendorf |
|---|---|
| Next by Date: | Re: =?utf-8?q?PMDAs_for_lm=5Fsensors=2C_HDD_SMART_monitoring?= =?utf-8?b?4oCP?=, Frank Ch. Eigler |
| Previous by Thread: | Re: PMDAs for lm_sensors, HDD SMART monitoringâ, Frank Ch. Eigler |
| Next by Thread: | Re: =?utf-8?q?PMDAs_for_lm=5Fsensors=2C_HDD_SMART_monitoring?= =?utf-8?b?4oCP?=, Frank Ch. Eigler |
| Indexes: | [Date] [Thread] [Top] [All Lists] |