aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTomas Halman <thalman@redhat.com>2021-03-12 12:57:57 +0100
committerJake Hunsaker <jhunsake@redhat.com>2021-03-16 11:50:44 -0400
commit847b2667351c845540e8801f81578c1d3737198a (patch)
treef25eb6e83a50e7c44c7f4241cc9a0f4983423b3e
parenta9749afbb87fbda625e1e2ef27ff82c8f65f61a6 (diff)
downloadsos-847b2667351c845540e8801f81578c1d3737198a.tar.gz
[sssd] Add individual SSSD log files
The issue is that SSSD creates individual log files for its components. To be able to track the issue we need all of them. With one wildcard copy set we usually get just one truncated log file and this is not very useful for solving issues. We need to track the request accross logs to understand the problem. Also log file names are specific for paricular configuration. With this patch we list log files under /var/log/sssd and we add them one by one. Resolves: #2445 Signed-off-by: Tomas Halman <thalman@redhat.com> Signed-off-by: Jake Hunsaker <jhunsake@redhat.com>
-rw-r--r--sos/report/plugins/sssd.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/sos/report/plugins/sssd.py b/sos/report/plugins/sssd.py
index 2058d90c..9469c41c 100644
--- a/sos/report/plugins/sssd.py
+++ b/sos/report/plugins/sssd.py
@@ -10,6 +10,7 @@
from sos.report.plugins import (Plugin, RedHatPlugin, DebianPlugin,
UbuntuPlugin, SoSPredicate)
+from glob import glob
class Sssd(Plugin):
@@ -23,12 +24,14 @@ class Sssd(Plugin):
def setup(self):
self.add_copy_spec([
"/etc/sssd/sssd.conf",
- "/var/log/sssd/*",
"/var/lib/sss/pubconf/krb5.include.d/*",
# SSSD 1.14
"/etc/sssd/conf.d/*.conf"
])
+ # add individual log files
+ self.add_copy_spec(glob("/var/log/sssd/*log*"))
+
# call sssctl commands only when sssd service is running,
# otherwise the command timeouts
sssd_pred = SoSPredicate(self, services=["sssd"])