aboutsummaryrefslogtreecommitdiffstats
path: root/src/sosreport
diff options
context:
space:
mode:
authorjwbernin <jwbernin@ef72aa8b-4018-0410-8976-d6e080ef94d8>2006-07-22 19:49:23 +0000
committerjwbernin <jwbernin@ef72aa8b-4018-0410-8976-d6e080ef94d8>2006-07-22 19:49:23 +0000
commit358e5ba36c8b17745d96790cb125eb2160817387 (patch)
tree0fc1c737600909aabd783e337c33eb2ac80af607 /src/sosreport
parentabfe72dbf66581eee17ef1cab556a4d234166068 (diff)
downloadsos-358e5ba36c8b17745d96790cb125eb2160817387.tar.gz
Merging jwb-dev branch to trunk
git-svn-id: svn+ssh://svn.fedorahosted.org/svn/sos/trunk@36 ef72aa8b-4018-0410-8976-d6e080ef94d8
Diffstat (limited to 'src/sosreport')
-rwxr-xr-xsrc/sosreport12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/sosreport b/src/sosreport
index 5ebea18f..5aa7063f 100755
--- a/src/sosreport
+++ b/src/sosreport
@@ -26,6 +26,7 @@ from optparse import OptionParser
import sos.policyredhat
from sos.helpers import *
from snack import *
+from threading import Thread
if os.getuid() != 0:
print 'You must run sosreport as root!'
@@ -109,6 +110,7 @@ def sosreport():
"This is the top-level function that gathers and processes all sosreport information"
loadedplugins = []
alloptions = []
+ threads = []
# TODO automatically locate the policy module??
policy = sos.policyredhat.SosPolicy()
@@ -206,9 +208,17 @@ def sosreport():
for plug, plugname, optname, optparm in alloptions:
plug.setOption(optname,1)
+ # Call the setup method for each plugin
+ for plugname, plug in loadedplugins:
+ plug.setup()
+
# Call the collect method for each plugin
for plugname, plug in loadedplugins:
- plug.collect()
+ plug.doCollect()
+
+ # Wait for all the collcetion threads to exit
+ for plugname, plug in loadedplugins:
+ plug.wait()
# Call the analyze method for each plugin
for plugname, plug in loadedplugins: