aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJesse Jaggars <jjaggars@redhat.com>2012-03-12 09:11:38 -0500
committerJesse Jaggars <jjaggars@redhat.com>2012-03-12 09:11:38 -0500
commit3570f8e00be445000975b256d2a1e6b622dc81c5 (patch)
tree5102e23764282112754c95a9647e40ff76aec94c
parentc04ff1d53c78bd08494d2b7038938953548b3ae7 (diff)
parent2356c7d61518fdde0fa245305eb74cd3a92a79cc (diff)
downloadsos-3570f8e00be445000975b256d2a1e6b622dc81c5.tar.gz
Merge branch 'master' of github.com:sosreport/sosreport
-rw-r--r--README1
-rw-r--r--sos/plugins/crontab.py8
-rw-r--r--sos/plugins/hardware.py10
-rw-r--r--sos/plugins/i18n.py7
-rw-r--r--sos/plugins/ipsec.py24
-rw-r--r--sos/plugins/iscsi.py25
-rw-r--r--sos/plugins/memory.py4
-rw-r--r--sos/plugins/nscd.py5
-rw-r--r--sos/plugins/openssl.py23
-rw-r--r--sos/plugins/radius.py26
-rw-r--r--sos/plugins/sssd.py21
-rw-r--r--sos/plugins/x11.py5
12 files changed, 128 insertions, 31 deletions
diff --git a/README b/README
index 7d51248d..4d4f415e 100644
--- a/README
+++ b/README
@@ -12,6 +12,7 @@ To access to the public source code repository for this project run:
to install locally (as root) ==> make install
to build an rpm ==> make rpm
+to build a deb ==> make deb-unsign
to build a zipfile for use with jython ==> make zip
Debian/Ubuntu users can install via PPA:
diff --git a/sos/plugins/crontab.py b/sos/plugins/crontab.py
index ae0a55d3..3df0a688 100644
--- a/sos/plugins/crontab.py
+++ b/sos/plugins/crontab.py
@@ -12,12 +12,14 @@
## along with this program; if not, write to the Free Software
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-from sos.plugins import Plugin, RedHatPlugin
-import os
+from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin
-class crontab(Plugin, RedHatPlugin):
+class crontab(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
"""Crontab information
"""
+
+ plugin_name = "crontab"
+
def setup(self):
self.addCopySpec("/etc/cron*")
self.collectExtOutput("/usr/bin/crontab -l -u root", suggest_filename = "root_crontab")
diff --git a/sos/plugins/hardware.py b/sos/plugins/hardware.py
index 7398656a..762732c3 100644
--- a/sos/plugins/hardware.py
+++ b/sos/plugins/hardware.py
@@ -15,7 +15,7 @@
from sos.plugins import Plugin, RedHatPlugin, UbuntuPlugin, DebianPlugin
from glob import glob
-class hardware(Plugin, DebianPlugin, UbuntuPlugin):
+class hardware(Plugin):
"""hardware related information
"""
@@ -60,3 +60,11 @@ class RedHatHardware(hardware, RedHatPlugin):
def setup(self):
super(RedHatHardware, self).setup()
self.collectExtOutput(glob("/usr/share/rhn/up2date*client/hardware.py")[0]) # RHBZ#572353
+
+
+class DebianHardware(hardware, DebianPlugin, UbuntuPlugin):
+ """hardware related information for Debian distribution
+ """
+
+ def setup(self):
+ super(DebianHardware, self).setup()
diff --git a/sos/plugins/i18n.py b/sos/plugins/i18n.py
index 2640f32d..fb87f98c 100644
--- a/sos/plugins/i18n.py
+++ b/sos/plugins/i18n.py
@@ -12,12 +12,11 @@
## along with this program; if not, write to the Free Software
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-from sos.plugins import Plugin, RedHatPlugin
-import os
+from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin
-class i18n(Plugin, RedHatPlugin):
+class i18n(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
"""i18n related information
"""
def setup(self):
self.addCopySpec("/etc/X11/xinit/xinput.d/*")
- self.collectExtOutput("/usr/bin/locale")
+ self.collectExtOutput("/usr/bin/locale")
diff --git a/sos/plugins/ipsec.py b/sos/plugins/ipsec.py
index 994b8f1b..67923801 100644
--- a/sos/plugins/ipsec.py
+++ b/sos/plugins/ipsec.py
@@ -14,15 +14,31 @@
## along with this program; if not, write to the Free Software
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-from sos.plugins import Plugin, RedHatPlugin
-from os.path import exists
+from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin
-class ipsec(Plugin, RedHatPlugin):
+class ipsec(Plugin):
"""ipsec related information
"""
- files = ('/etc/racoon/racoon.conf',)
+ plugin_name = "ipsec"
packages = ('ipsec-tools',)
+class RedHatIpsec(ipsec, RedHatPlugin):
+ """ipsec related information for Red Hat distributions
+ """
+
+ files = ('/etc/racoon/racoon.conf',)
+
def setup(self):
self.addCopySpec("/etc/racoon")
+
+class DebianIpsec(ipsec, DebianPlugin, UbuntuPlugin):
+ """ipsec related information for Debian distributions
+ """
+
+ files = ('/etc/ipsec-tools.conf',)
+
+ def setup(self):
+ self.addCopySpecs(["/etc/ipsec-tools.conf",
+ "/etc/ipsec-tools.d",
+ "/etc/default/setkey"])
diff --git a/sos/plugins/iscsi.py b/sos/plugins/iscsi.py
index 56c5149b..08e82db4 100644
--- a/sos/plugins/iscsi.py
+++ b/sos/plugins/iscsi.py
@@ -12,13 +12,34 @@
## along with this program; if not, write to the Free Software
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-from sos.plugins import Plugin, RedHatPlugin
+from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin
-class iscsi(Plugin, RedHatPlugin):
+class iscsi(Plugin):
"""iscsi-initiator related information
"""
+
+ plugin_name = "iscsi"
+
+class RedHatIscsi(iscsi, RedHatPlugin):
+ """iscsi-initiator related information Red Hat based distributions
+ """
def setup(self):
+ super(RedHatIscsi, self).setup()
self.addCopySpecs([
"/etc/iscsi/iscsid.conf",
"/etc/iscsi/initiatorname.iscsi",
"/var/lib/iscsi"])
+
+class DebianIscsi(iscsi, DebianPlugin, UbuntuPlugin):
+ """iscsi-initiator related information Debian based distributions
+ """
+
+ packages = ('iscsitarget',)
+
+ def setup(self):
+ super(DebianIscsi, self).setup()
+ self.addCopySpecs([
+ "/etc/iet",
+ "/etc/sysctl.d/30-iscsitarget.conf",
+ "/etc/default/iscsitarget"
+ ])
diff --git a/sos/plugins/memory.py b/sos/plugins/memory.py
index 3ee8ef7e..8bb837fd 100644
--- a/sos/plugins/memory.py
+++ b/sos/plugins/memory.py
@@ -12,9 +12,9 @@
## along with this program; if not, write to the Free Software
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-from sos.plugins import Plugin, RedHatPlugin
+from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin
-class memory(Plugin, RedHatPlugin):
+class memory(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
"""memory usage information
"""
def setup(self):
diff --git a/sos/plugins/nscd.py b/sos/plugins/nscd.py
index 26ec3afc..5c98e864 100644
--- a/sos/plugins/nscd.py
+++ b/sos/plugins/nscd.py
@@ -14,10 +14,9 @@
## along with this program; if not, write to the Free Software
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-from sos.plugins import Plugin, RedHatPlugin
-from os.path import exists
+from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin
-class nscd(Plugin, RedHatPlugin):
+class nscd(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
"""NSCD related information
"""
diff --git a/sos/plugins/openssl.py b/sos/plugins/openssl.py
index 07f8a35b..9bf3e574 100644
--- a/sos/plugins/openssl.py
+++ b/sos/plugins/openssl.py
@@ -14,14 +14,31 @@
## along with this program; if not, write to the Free Software
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-from sos.plugins import Plugin, RedHatPlugin
+from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin
-class openssl(Plugin, RedHatPlugin):
+class openssl(Plugin):
"""openssl related information
"""
- files = ('/etc/pki/tls/openssl.cnf',)
+ plugin_name = "openssl"
packages = ('openssl',)
+class RedHatOpenssl(openssl, RedHatPlugin):
+ """openssl related information for Red Hat distributions
+ """
+
+ files = ('/etc/pki/tls/openssl.cnf',)
+
def setup(self):
+ super(RedHatOpenssl, self).setup()
self.addCopySpec("/etc/pki/tls/openssl.cnf")
+
+class DebianOpenssl(openssl, DebianPlugin, UbuntuPlugin):
+ """openssl related information for Debian distributions
+ """
+
+ files = ('/etc/ssl/openssl.cnf',)
+
+ def setup(self):
+ super(DebianOpenssl, self).setup()
+ self.addCopySpec("/etc/ssl/openssl.cnf")
diff --git a/sos/plugins/radius.py b/sos/plugins/radius.py
index 32980626..df1442b1 100644
--- a/sos/plugins/radius.py
+++ b/sos/plugins/radius.py
@@ -14,18 +14,38 @@
## along with this program; if not, write to the Free Software
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-from sos.plugins import Plugin, RedHatPlugin
+from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin
from os.path import exists
-class radius(Plugin, RedHatPlugin):
+class radius(Plugin):
"""radius related information
"""
- files = ('/etc/raddb',)
+ plugin_name = "radius"
packages = ('freeradius',)
+class RedHatRadius(radius, RedHatPlugin):
+ """radius related information on Red Hat distributions
+ """
+
+ files = ('/etc/raddb',)
+
def setup(self):
+ super(RedHatRadius, self).setup()
self.addCopySpecs(["/etc/raddb", "/etc/pam.d/radiusd", "/var/log/radius"])
def postproc(self):
self.doRegexSub("/etc/raddb/sql.conf", r"(\s*password\s*=\s*)\S+", r"\1***")
+
+class DebianRadius(radius, DebianPlugin, UbuntuPlugin):
+ """radius related information on Debian distributions
+ """
+
+ files = ('/etc/freeradius',)
+
+ def setup(self):
+ super(DebianRadius, self).setup()
+ self.addCopySpecs(["/etc/freeradius",
+ "/etc/pam.d/radiusd",
+ "/etc/default/freeradius",
+ "/var/log/freeradius"])
diff --git a/sos/plugins/sssd.py b/sos/plugins/sssd.py
index 8e6e4edf..fae9b8b7 100644
--- a/sos/plugins/sssd.py
+++ b/sos/plugins/sssd.py
@@ -14,14 +14,29 @@
## along with this program; if not, write to the Free Software
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-from sos.plugins import Plugin, RedHatPlugin
-import os
+from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin
-class sssd(Plugin, RedHatPlugin):
+class sssd(Plugin):
"""sssd-related Diagnostic Information
"""
+ plugin_name = "sssd"
packages = ('sssd',)
def setup(self):
self.addCopySpecs(["/etc/sssd", "/var/log/sssd/*"])
+
+class RedHatSssd(sssd, RedHatPlugin):
+ """sssd-related Diagnostic Information on Red Hat based distributions
+ """
+
+ def setup(self):
+ super(RedHatSssd, self).setup()
+
+class DebianSssd(sssd, DebianPlugin, UbuntuPlugin):
+ """sssd-related Diagnostic Information on Debian based distributions
+ """
+
+ def setup(self):
+ super(DebianSssd, self).setup()
+ self.addCopySpecs(["/etc/default/sssd"])
diff --git a/sos/plugins/x11.py b/sos/plugins/x11.py
index 22c77617..a760e6bc 100644
--- a/sos/plugins/x11.py
+++ b/sos/plugins/x11.py
@@ -12,10 +12,9 @@
## along with this program; if not, write to the Free Software
## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-from sos.plugins import Plugin, RedHatPlugin
-from os.path import exists
+from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin
-class x11(Plugin, RedHatPlugin):
+class x11(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
"""X related information
"""