From 8eff8f82604cb83a4c43f4a3ba0308940863c1b5 Mon Sep 17 00:00:00 2001
From: Pavel Moravec <pmoravec@redhat.com>
Date: Mon, 29 Jul 2019 11:34:06 +0200
Subject: [PATCH] [nvme] collect config file everytime
Collect /etc/nvme/discovery.conf every time, outside any for-loop block.
Resolves: #1740
Signed-off-by: Pavel Moravec <pmoravec@redhat.com>
---
sos/plugins/nvme.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sos/plugins/nvme.py b/sos/plugins/nvme.py
index 6e2cda73..bd9d2df0 100644
--- a/sos/plugins/nvme.py
+++ b/sos/plugins/nvme.py
@@ -21,6 +21,7 @@ class Nvme(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
return [dev for dev in sys_block if dev.startswith('nvme')]
def setup(self):
+ self.add_copy_spec("/etc/nvme/discovery.conf")
self.add_cmd_output([
"nvme list",
"nvme list-subsys",
@@ -39,6 +40,5 @@ class Nvme(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
"nvme show-regs /dev/%s" % dev,
"nvme get-ns-id /dev/%s" % dev
])
- self.add_copy_spec("/etc/nvme/discovery.conf")
# vim: set et ts=4 sw=4 :
--
2.21.0