aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPavel Moravec <pmoravec@redhat.com>2017-10-02 16:56:57 +0200
committerBryn M. Reeves <bmr@redhat.com>2017-10-31 15:40:22 +0000
commit4374436c286086006568487dcc71b9e1ccb0bedb (patch)
tree574c6c2b9bd46fc650ad1134588a8cd129e12ce3
parent5b7cc37f18e70345de999a888f377b7f710dda28 (diff)
downloadsos-4374436c286086006568487dcc71b9e1ccb0bedb.tar.gz
[openvswitch] Collect all logs
Do not collect just 2 logfiles but all from the log directory. Resolves: #1116 Signed-off-by: Pavel Moravec <pmoravec@redhat.com>
-rw-r--r--sos/plugins/openvswitch.py12
1 files changed, 10 insertions, 2 deletions
diff --git a/sos/plugins/openvswitch.py b/sos/plugins/openvswitch.py
index e50111ac..b3bc4054 100644
--- a/sos/plugins/openvswitch.py
+++ b/sos/plugins/openvswitch.py
@@ -25,9 +25,17 @@ class OpenVSwitch(Plugin):
def setup(self):
+ all_logs = self.get_option("all_logs")
+ limit = self.get_option("log_size")
+
+ if not all_logs:
+ self.add_copy_spec("/var/log/openvswitch/*.log",
+ sizelimit=limit)
+ else:
+ self.add_copy_spec("/var/log/openvswitch/",
+ sizelimit=limit)
+
self.add_copy_spec([
- "/var/log/openvswitch/ovs-vswitchd.log",
- "/var/log/openvswitch/ovsdb-server.log",
"/var/run/openvswitch/ovsdb-server.pid",
"/var/run/openvswitch/ovs-vswitchd.pid"
])