aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Pittman <jpittman@redhat.com>2018-11-29 20:45:09 -0500
committerBryn M. Reeves <bmr@redhat.com>2019-03-19 17:03:58 +0000
commitc5a772df3c7c62a77c325f356cc156c505ede926 (patch)
tree4ce797d0761ce29c462e7edc7c1f8a6d16c73e67
parenta2f8648fb31253df3969d36bd086be499a366974 (diff)
downloadsos-c5a772df3c7c62a77c325f356cc156c505ede926.tar.gz
[scsi] collect scsi_host sysfs host values
The scsi_host attributes can be very important when identifying LLD/shost level issues. Add host value collection via udevadm. Signed-off-by: John Pittman <jpittman@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
-rw-r--r--sos/plugins/scsi.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/sos/plugins/scsi.py b/sos/plugins/scsi.py
index d3b2c332..3be613c6 100644
--- a/sos/plugins/scsi.py
+++ b/sos/plugins/scsi.py
@@ -6,6 +6,8 @@
#
# See the LICENSE file in the source distribution for further information.
+import os
+from glob import glob
from sos.plugins import Plugin, RedHatPlugin, UbuntuPlugin, DebianPlugin
@@ -32,4 +34,7 @@ class Scsi(Plugin, RedHatPlugin, UbuntuPlugin, DebianPlugin):
"sg_map -x"
])
+ scsi_hosts = glob("/sys/class/scsi_host/*")
+ self.add_udev_info(scsi_hosts, attrs=True)
+
# vim: set et ts=4 sw=4 :