Blame SOURCES/sos-bz1194159-kernel-additional-diagnostic.patch

c81b6a
From 9c1e646da727817de23c0b46a16885c03c7d4af1 Mon Sep 17 00:00:00 2001
c81b6a
From: "Bryn M. Reeves" <bmr@redhat.com>
c81b6a
Date: Tue, 10 Feb 2015 19:34:50 +0000
c81b6a
Subject: [PATCH] [kernel] collect /sys/firmware/acpi/*
c81b6a
c81b6a
Collect ACPI firmware tables and state from /sys.
c81b6a
c81b6a
Related: #490.
c81b6a
c81b6a
Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
c81b6a
---
c81b6a
 sos/plugins/kernel.py | 1 +
c81b6a
 1 file changed, 1 insertion(+)
c81b6a
c81b6a
diff --git a/sos/plugins/kernel.py b/sos/plugins/kernel.py
c81b6a
index 877b2bb..6b93ab7 100644
c81b6a
--- a/sos/plugins/kernel.py
c81b6a
+++ b/sos/plugins/kernel.py
c81b6a
@@ -49,6 +49,7 @@ class Kernel(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
c81b6a
             "/sys/module/*/initstate",
c81b6a
             "/sys/module/*/refcnt",
c81b6a
             "/sys/module/*/taint",
c81b6a
+            "/sys/firmware/acpi/*",
c81b6a
             "/proc/kallsyms",
c81b6a
             "/proc/buddyinfo",
c81b6a
             "/proc/slabinfo",
c81b6a
-- 
c81b6a
1.8.3.1
c81b6a
c81b6a
From 14686f55bd5bc7169eb06a871ada7bc3461b306b Mon Sep 17 00:00:00 2001
c81b6a
From: "Bryn M. Reeves" <bmr@redhat.com>
c81b6a
Date: Tue, 10 Feb 2015 19:43:08 +0000
c81b6a
Subject: [PATCH] [memory] add ksm, swap and vmallocinfo data to plugin
c81b6a
c81b6a
Related: #490.
c81b6a
c81b6a
Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
c81b6a
---
c81b6a
 sos/plugins/memory.py | 11 +++++++++--
c81b6a
 1 file changed, 9 insertions(+), 2 deletions(-)
c81b6a
c81b6a
diff --git a/sos/plugins/memory.py b/sos/plugins/memory.py
c81b6a
index 0f20e99..1b27eba 100644
c81b6a
--- a/sos/plugins/memory.py
c81b6a
+++ b/sos/plugins/memory.py
c81b6a
@@ -27,9 +27,16 @@ class Memory(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
c81b6a
             "/proc/pci",
c81b6a
             "/proc/meminfo",
c81b6a
             "/proc/vmstat",
c81b6a
+            "/proc/swaps",
c81b6a
             "/proc/slabinfo",
c81b6a
-            "/proc/pagetypeinfo"])
c81b6a
+            "/proc/pagetypeinfo",
c81b6a
+            "/proc/vmallocinfo",
c81b6a
+            "/sys/kernel/mm/ksm"
c81b6a
+        ])
c81b6a
         self.add_cmd_output("free", root_symlink="free")
c81b6a
-        self.add_cmd_output("free -m")
c81b6a
+        self.add_cmd_output([
c81b6a
+            "free -m",
c81b6a
+            "swapon --show"
c81b6a
+        ])
c81b6a
 
c81b6a
 # vim: et ts=4 sw=4
c81b6a
-- 
c81b6a
1.8.3.1
c81b6a
c81b6a
From 58a6d777d7b5fc4ef72e185ccd916110a73f48d2 Mon Sep 17 00:00:00 2001
c81b6a
From: "Bryn M. Reeves" <bmr@redhat.com>
c81b6a
Date: Tue, 10 Feb 2015 19:47:14 +0000
c81b6a
Subject: [PATCH] [block] collect /proc/diskstats
c81b6a
c81b6a
Related: #490.
c81b6a
c81b6a
Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
c81b6a
---
c81b6a
 sos/plugins/block.py | 6 +++---
c81b6a
 1 file changed, 3 insertions(+), 3 deletions(-)
c81b6a
c81b6a
diff --git a/sos/plugins/block.py b/sos/plugins/block.py
c81b6a
index 8c73ef6..7984f0d 100644
c81b6a
--- a/sos/plugins/block.py
c81b6a
+++ b/sos/plugins/block.py
c81b6a
@@ -24,8 +24,6 @@ class Block(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
c81b6a
     profiles = ('storage', 'hardware')
c81b6a
 
c81b6a
     def setup(self):
c81b6a
-        self.add_copy_spec("/proc/partitions")
c81b6a
-
c81b6a
         self.add_cmd_output([
c81b6a
             "lsblk",
c81b6a
             "blkid -c /dev/null",
c81b6a
@@ -36,7 +34,9 @@ class Block(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
c81b6a
         # legacy location for non-/run distributions
c81b6a
         self.add_copy_spec([
c81b6a
             "/etc/blkid.tab",
c81b6a
-            "/run/blkid/blkid.tab"
c81b6a
+            "/run/blkid/blkid.tab",
c81b6a
+            "/proc/partitions",
c81b6a
+            "/proc/diskstats"
c81b6a
         ])
c81b6a
 
c81b6a
         if os.path.isdir("/sys/block"):
c81b6a
-- 
c81b6a
1.8.3.1
c81b6a
c81b6a
From 4cc076409f65792c071e4cf027a78c847f7b5ff8 Mon Sep 17 00:00:00 2001
c81b6a
From: "Bryn M. Reeves" <bmr@redhat.com>
c81b6a
Date: Tue, 10 Feb 2015 19:48:59 +0000
c81b6a
Subject: [PATCH] [process] collect /proc/sched_debug
c81b6a
c81b6a
Related: #490.
c81b6a
c81b6a
Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
c81b6a
---
c81b6a
 sos/plugins/process.py | 1 +
c81b6a
 1 file changed, 1 insertion(+)
c81b6a
c81b6a
diff --git a/sos/plugins/process.py b/sos/plugins/process.py
c81b6a
index ab66322..cae8443 100644
c81b6a
--- a/sos/plugins/process.py
c81b6a
+++ b/sos/plugins/process.py
c81b6a
@@ -23,6 +23,7 @@ class Process(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
c81b6a
     profiles = ('system',)
c81b6a
 
c81b6a
     def setup(self):
c81b6a
+        self.add_copy_spec("/proc/sched_debug")
c81b6a
         self.add_cmd_output("ps auxwww", root_symlink="ps")
c81b6a
         self.add_cmd_output("pstree", root_symlink="pstree")
c81b6a
         self.add_cmd_output("lsof -b +M -n -l", root_symlink="lsof")
c81b6a
-- 
c81b6a
1.8.3.1
c81b6a
c81b6a
From f3ec78df7060c4ac3cead99775f162a9b5d604f7 Mon Sep 17 00:00:00 2001
c81b6a
From: "Bryn M. Reeves" <bmr@redhat.com>
c81b6a
Date: Wed, 11 Feb 2015 20:06:59 +0000
c81b6a
Subject: [PATCH] [kernel] collect directory listings for module updates
c81b6a
c81b6a
Related #490.
c81b6a
c81b6a
Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
c81b6a
---
c81b6a
 sos/plugins/kernel.py | 14 +++++++++++++-
c81b6a
 1 file changed, 13 insertions(+), 1 deletion(-)
c81b6a
c81b6a
diff --git a/sos/plugins/kernel.py b/sos/plugins/kernel.py
c81b6a
index 6b93ab7..97300e2 100644
c81b6a
--- a/sos/plugins/kernel.py
c81b6a
+++ b/sos/plugins/kernel.py
c81b6a
@@ -14,6 +14,7 @@
c81b6a
 
c81b6a
 from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin
c81b6a
 import os
c81b6a
+import glob
c81b6a
 
c81b6a
 
c81b6a
 class Kernel(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
c81b6a
@@ -36,10 +37,21 @@ class Kernel(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
c81b6a
         except OSError:
c81b6a
             self._log_warn("could not list %s" % self.sys_module)
c81b6a
 
c81b6a
+        # find /lib/modules/*/{extras,updates,weak-updates} -ls
c81b6a
+        extra_mod_patterns = [
c81b6a
+            "/lib/modules/*/extra",
c81b6a
+            "/lib/modules/*/updates",
c81b6a
+            "/lib/modules/*/weak-updates",
c81b6a
+        ]
c81b6a
+        extra_mod_paths = []
c81b6a
+        for pattern in extra_mod_patterns:
c81b6a
+            extra_mod_paths.extend(glob.glob(pattern))
c81b6a
+
c81b6a
         self.add_cmd_output([
c81b6a
             "dmesg",
c81b6a
             "sysctl -a",
c81b6a
-            "dkms status"
c81b6a
+            "dkms status",
c81b6a
+            "find %s -ls" % " ".join(extra_mod_paths)
c81b6a
         ])
c81b6a
 
c81b6a
         self.add_copy_spec([
c81b6a
-- 
c81b6a
1.8.3.1
c81b6a
c81b6a
From 895803a4c7d014b231cfe9804bd1c04fe37b5f5e Mon Sep 17 00:00:00 2001
c81b6a
From: "Bryn M. Reeves" <bmr@redhat.com>
c81b6a
Date: Wed, 11 Feb 2015 20:15:37 +0000
c81b6a
Subject: [PATCH] [mpt] add plugin
c81b6a
c81b6a
Add a plugin to collect LSI Message Passing Technology driver
c81b6a
status from /proc.
c81b6a
c81b6a
Related: #490.
c81b6a
c81b6a
Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
c81b6a
---
c81b6a
 sos/plugins/mpt.py | 30 ++++++++++++++++++++++++++++++
c81b6a
 1 file changed, 30 insertions(+)
c81b6a
 create mode 100644 sos/plugins/mpt.py
c81b6a
c81b6a
diff --git a/sos/plugins/mpt.py b/sos/plugins/mpt.py
c81b6a
new file mode 100644
c81b6a
index 0000000..bb158cc
c81b6a
--- /dev/null
c81b6a
+++ b/sos/plugins/mpt.py
c81b6a
@@ -0,0 +1,30 @@
c81b6a
+# Copyright (C) 2015 Red Hat, Inc., Bryn M. Reeves <bmr@redhat.com>
c81b6a
+
c81b6a
+# This program is free software; you can redistribute it and/or modify
c81b6a
+# it under the terms of the GNU General Public License as published by
c81b6a
+# the Free Software Foundation; either version 2 of the License, or
c81b6a
+# (at your option) any later version.
c81b6a
+
c81b6a
+# This program is distributed in the hope that it will be useful,
c81b6a
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
c81b6a
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
c81b6a
+# GNU General Public License for more details.
c81b6a
+
c81b6a
+# You should have received a copy of the GNU General Public License
c81b6a
+# along with this program; if not, write to the Free Software
c81b6a
+# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
c81b6a
+
c81b6a
+from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin
c81b6a
+
c81b6a
+
c81b6a
+class Mpt(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
c81b6a
+    """ LSI Message Passing Technology
c81b6a
+    """
c81b6a
+    files = ('/proc/mpt',)
c81b6a
+    profiles = ('storage', )
c81b6a
+    plugin_name = 'mpt'
c81b6a
+
c81b6a
+    def setup(self):
c81b6a
+        self.add_copy_spec("/proc/mpt")
c81b6a
+
c81b6a
+# vim: et ts=4 sw=4
c81b6a
-- 
c81b6a
1.8.3.1
c81b6a
c81b6a
From fc4e2be53eeeaa9ab0d4d089335bbeb007c1817e Mon Sep 17 00:00:00 2001
c81b6a
From: "Bryn M. Reeves" <bmr@redhat.com>
c81b6a
Date: Thu, 27 Aug 2015 18:07:46 +0100
c81b6a
Subject: [PATCH] [memory] collect swapon --show output in bytes
c81b6a
c81b6a
Default is human readable:
c81b6a
c81b6a
$ swapon --show
c81b6a
NAME      TYPE      SIZE USED PRIO
c81b6a
/dev/dm-0 partition 1.5G   0B   -1
c81b6a
c81b6a
Should be:
c81b6a
c81b6a
$ swapon --show --bytes
c81b6a
NAME      TYPE            SIZE USED PRIO
c81b6a
/dev/dm-0 partition 1610608640    0   -1
c81b6a
c81b6a
Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
c81b6a
---
c81b6a
 sos/plugins/memory.py | 2 +-
c81b6a
 1 file changed, 1 insertion(+), 1 deletion(-)
c81b6a
c81b6a
diff --git a/sos/plugins/memory.py b/sos/plugins/memory.py
c81b6a
index 4c41896..710f73f 100644
c81b6a
--- a/sos/plugins/memory.py
c81b6a
+++ b/sos/plugins/memory.py
c81b6a
@@ -36,7 +36,7 @@ class Memory(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
c81b6a
         self.add_cmd_output("free", root_symlink="free")
c81b6a
         self.add_cmd_output([
c81b6a
             "free -m",
c81b6a
-            "swapon --show"
c81b6a
+            "swapon --bytes --show"
c81b6a
         ])
c81b6a
 
c81b6a
 # vim: et ts=4 sw=4
c81b6a
-- 
c81b6a
1.8.3.1
c81b6a