From d1d21e742563a7df087692f7d5b3d60c0f0e5829 Mon Sep 17 00:00:00 2001 From: Yaarit Hatuka Date: Tue, 5 Dec 2017 09:25:00 -0500 Subject: [PATCH 1/5] DNM osd: add 'ceph [tell|daemon] osd.id smart' Also added 'ceph daemon osd.id list_devices' which prints to stdout the osd devices. 'ceph [tell|daemon] osd.id smart' probes the osd devices for SMART data and prints it to stdout in a JSON format. It assumes smartctl '--json' feature exists. Signed-off-by: Yaarit Hatuka --- src/common/options.cc | 4 ++ src/osd/OSD.cc | 107 +++++++++++++++++++++++++++++++ src/osd/OSD.h | 3 + src/pybind/mgr/smart/__init__.py | 2 + src/pybind/mgr/smart/module.py | 35 ++++++++++ 5 files changed, 151 insertions(+) create mode 100644 src/pybind/mgr/smart/__init__.py create mode 100644 src/pybind/mgr/smart/module.py diff --git a/src/common/options.cc b/src/common/options.cc index b286457b9b35f..ee73aa106b9fb 100644 --- a/src/common/options.cc +++ b/src/common/options.cc @@ -1632,6 +1632,10 @@ std::vector