import sos-3.8-7.el8_2

This commit is contained in:
CentOS Sources 2020-09-08 04:38:45 -04:00 committed by Andrew Lukoshko
parent 175df27946
commit 547f384876
3 changed files with 129 additions and 1 deletions

View File

@ -0,0 +1,36 @@
From 5b5302e7a7b1931d51e4960a9a56f14cd0c855c1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Renaud=20M=C3=A9trich?= <rmetrich@redhat.com>
Date: Tue, 10 Mar 2020 13:38:55 +0100
Subject: [PATCH] [selinux] collect /var/lib/selinux
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
On RHEL 8, modules and contexts are not in /etc/selinux/<policy>
directory anymore, but in /var/lib/selinux/<policy> directory.
Resolves: #1976
Signed-off-by: Renaud Métrich <rmetrich@redhat.com>
Signed-off-by: Jake Hunsaker <jhunsake@redhat.com>
---
sos/plugins/selinux.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/sos/plugins/selinux.py b/sos/plugins/selinux.py
index 1e9f24ca..d98b6745 100644
--- a/sos/plugins/selinux.py
+++ b/sos/plugins/selinux.py
@@ -23,7 +23,8 @@ class SELinux(Plugin, RedHatPlugin):
def setup(self):
self.add_copy_spec([
'/etc/sestatus.conf',
- '/etc/selinux'
+ '/etc/selinux',
+ '/var/lib/selinux'
])
self.add_cmd_output('sestatus')
--
2.26.2

View File

@ -0,0 +1,82 @@
From 2b46bf710ff266a5727f5c101872c778d470dcb4 Mon Sep 17 00:00:00 2001
From: Jan Jansky <jjansky@redhat.com>
Date: Wed, 15 Jul 2020 13:38:52 +0200
Subject: [PATCH] [gluster] remove only dump files
Removes only dump files and leaving
other files as .socket or sock.
Resolves: #2152
Signed-off-by: Jan Jansky <jjansky@redhat.com>
Signed-off-by: Jake Hunsaker <jhunsake@redhat.com>
---
sos/plugins/gluster.py | 17 ++++++++---------
1 file changed, 8 insertions(+), 9 deletions(-)
diff --git a/sos/plugins/gluster.py b/sos/plugins/gluster.py
index 9540d323..9815bbe7 100644
--- a/sos/plugins/gluster.py
+++ b/sos/plugins/gluster.py
@@ -40,15 +40,14 @@ class Gluster(Plugin, RedHatPlugin):
ret = string.count(last_line, 'DUMP_END_TIME')
def postproc(self):
- if not os.path.exists(self.statedump_dir):
- return
- try:
- for dirs in os.listdir(self.statedump_dir):
- os.remove(os.path.join(self.statedump_dir, dirs))
- os.rmdir(self.statedump_dir)
- os.unlink('/tmp/glusterdump.options')
- except OSError:
- pass
+ if self.get_option("dump"):
+ if not os.path.exists(self.statedump_dir):
+ return
+ try:
+ for name in glob.glob(self.statedump_dir + '/*.dump.[0-9]*'):
+ os.remove(name)
+ except OSError:
+ pass
def setup(self):
self.add_forbidden_path("/var/lib/glusterd/geo-replication/secret.pem")
--
2.26.2
From 7994ea1cc22ae256f08426ef37931b7b58f0fefc Mon Sep 17 00:00:00 2001
From: Jan Jansky <jjansky@redhat.com>
Date: Thu, 16 Jul 2020 14:34:49 +0200
Subject: [PATCH] [gluster] remove generated state files
Remove also generated state files in
/run/gluster.
Resolves: #2154
Signed-off-by: Jan Jansky <jjansky@redhat.com>
Signed-off-by: Jake Hunsaker <jhunsake@redhat.com>
---
sos/plugins/gluster.py | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/sos/plugins/gluster.py b/sos/plugins/gluster.py
index 9815bbe7..7b6a9298 100644
--- a/sos/plugins/gluster.py
+++ b/sos/plugins/gluster.py
@@ -45,7 +45,10 @@ class Gluster(Plugin, RedHatPlugin):
if not os.path.exists(self.statedump_dir):
return
try:
- for name in glob.glob(self.statedump_dir + '/*.dump.[0-9]*'):
+ remove_files = glob.glob(self.statedump_dir + '/*.dump.[0-9]*')
+ remove_files.extend(glob.glob(self.statedump_dir +
+ '/glusterd_state_[0-9]*_[0-9]*'))
+ for name in remove_files:
os.remove(name)
except OSError:
pass
--
2.26.2

View File

@ -5,7 +5,7 @@
Summary: A set of tools to gather troubleshooting information from a system
Name: sos
Version: 3.8
Release: 6%{?dist}
Release: 7%{?dist}
Group: Applications/System
Source0: https://github.com/sosreport/sos/archive/%{version}/sos-%{version}.tar.gz
Source1: sos-audit-%{auditversion}.tgz
@ -34,6 +34,8 @@ Patch11: sos-bz1741330-openswan-to-libreswan.patch
Patch12: sos-bz1709682-grub2-mkconfig-dont-remove-kernel-opts.patch
Patch13: sos-bz1831549-containers-common-plugin.patch
Patch14: sos-bz1838426-container_log-logdir.patch
Patch15: sos-bz1861710-collect-var-lib-selinux.patch
Patch16: sos-bz1861711-gluster-removes-sockfiles.patch
%description
Sos is a set of tools that gathers information about system
@ -57,6 +59,8 @@ support technicians and developers.
%patch12 -p1
%patch13 -p1
%patch14 -p1
%patch15 -p1
%patch16 -p1
%setup -T -D -a1 -q
%build
@ -109,6 +113,12 @@ of the system. Currently storage and filesystem commands are audited.
%ghost /etc/audit/rules.d/40-sos-storage.rules
%changelog
* Wed Jul 29 2020 Pavel Moravec <pmoravec@redhat.com> = 3.8-7
- [selinux] collect /var/lib/selinux
Resolves: bz1861710
- [gluster] remove only dump files
Resolves: bz1861711
* Thu May 21 2020 Pavel Moravec <pmoravec@redhat.com> = 3.8-6
- [container_log] fix unscoped 'logdir' variable
Resolves: bz1834421