aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib
diff options
context:
space:
mode:
authorastokes <astokes@ef72aa8b-4018-0410-8976-d6e080ef94d8>2010-01-06 16:50:54 +0000
committerastokes <astokes@ef72aa8b-4018-0410-8976-d6e080ef94d8>2010-01-06 16:50:54 +0000
commit938fe65f34bac7324c794ebe81b98c13a70a67a5 (patch)
treedd36444945a6ef1bb9b976e1f95b3199a0b4a59e /src/lib
parent9e5ea5da10a82ef9deedd88986d5325e49d81daa (diff)
downloadsos-938fe65f34bac7324c794ebe81b98c13a70a67a5.tar.gz
lots o bugfixes
git-svn-id: svn+ssh://svn.fedorahosted.org/svn/sos/trunk@671 ef72aa8b-4018-0410-8976-d6e080ef94d8
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/sos/plugins/cluster.py10
-rw-r--r--src/lib/sos/plugins/nscd.py12
-rw-r--r--src/lib/sos/plugins/sar.py2
3 files changed, 23 insertions, 1 deletions
diff --git a/src/lib/sos/plugins/cluster.py b/src/lib/sos/plugins/cluster.py
index 64860b5b..2e531532 100644
--- a/src/lib/sos/plugins/cluster.py
+++ b/src/lib/sos/plugins/cluster.py
@@ -202,6 +202,16 @@ class cluster(sos.plugintools.PluginBase):
# Test fence groups for valid id and state
self.test_fence_id()
+
+ # Check for existence of weak-updates in gfs2 prior to 2.6.18-128
+ if rhelver == 5:
+ vermagic = commands.getoutput("modinfo -F vermagic gfs2")
+ # just kernel release from vermagic line
+ vermagic = vermagic.split()[0].lstrip('2.6.18-')
+ vermagic = vermagic[:vermagic.find('.')]
+ if int(vermagic) < 128:
+ self.addDiagnose('GFS2 is being used via weak-updates, kmod-gfs2 should be uninstalled and system reboot' \
+ 'to allow for kernel provided gfs2 module to be used.')
def setup(self):
self.collectExtOutput("/sbin/fdisk -l")
diff --git a/src/lib/sos/plugins/nscd.py b/src/lib/sos/plugins/nscd.py
index ed0e2eb7..c79afe73 100644
--- a/src/lib/sos/plugins/nscd.py
+++ b/src/lib/sos/plugins/nscd.py
@@ -20,6 +20,10 @@ from os.path import exists
class nscd(sos.plugintools.PluginBase):
"""NSCD related information
"""
+
+ optionList = [("nscdlogsize", "max size (MiB) to collect per nscd log file",
+ "", 50)]
+
def checkenabled(self):
if self.cInfo["policy"].pkgByName("nscd") or exists("/etc/nscd.conf"):
return True
@@ -27,5 +31,13 @@ class nscd(sos.plugintools.PluginBase):
def setup(self):
self.addCopySpec("/etc/nscd.conf")
+
+ opt = self.fileGrep(r"^\s*logfile", "/etc/nscd.conf")
+ if (len(opt) > 0):
+ for o in opt:
+ f = o.split()
+ self.addCopySpecLimit(f[1],
+ sizelimit = self.isOptionEnabled("nscdlogsize"))
+
return
diff --git a/src/lib/sos/plugins/sar.py b/src/lib/sos/plugins/sar.py
index 26e97715..9a3b3c92 100644
--- a/src/lib/sos/plugins/sar.py
+++ b/src/lib/sos/plugins/sar.py
@@ -26,7 +26,7 @@ class sar(sos.plugintools.PluginBase):
if fname[0:2] == 'sa' and fname[2:3] != 'r':
sar_filename = 'sar' + fname[2:4]
if sar_filename not in dirList:
- sar_command = "/usr/bin/sar -A -f /var/log/sa/" + fname
+ sar_command = "/bin/sh -c \"LANG=C /usr/bin/sar -A -f /var/log/sa/" + fname + "\""
self.collectOutputNow(sar_command, sar_filename, root_symlink=sar_filename)
return