Module: check_mk
Branch: master
Commit: d88c9aba695fedd75b4fa7f13b60dadd1d78c81c
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=d88c9aba695fed…
Author: Andreas Boesl <ab(a)mathias-kettner.de>
Date: Wed Feb 22 16:49:36 2017 +0100
4032 smart agent plugin: disable megacli logging output
MegaCLI by default writes output to MegaSAS.log in the same directory.
With the smart plugin being called every 60 seconds this file can become
several GiB large. Disable logging similar to what is done in the main
agent.
Change-Id: I068d2d7da800d74d72194c3066cfdce6acef2c63
---
.werks/4032 | 13 +++++++++++++
agents/plugins/smart | 4 ++--
2 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/.werks/4032 b/.werks/4032
new file mode 100644
index 0000000..1f67a0f
--- /dev/null
+++ b/.werks/4032
@@ -0,0 +1,13 @@
+Title: smart agent plugin: disable megacli logging output
+Level: 1
+Component: checks
+Compatible: compat
+Edition: cre
+Version: 1.5.0i1
+Date: 1487778525
+Class: feature
+
+MegaCLI by default writes output to MegaSAS.log in the same directory.
+With the smart plugin being called every 60 seconds this file can become
+several GiB large. Disable logging similar to what is done in the main
+agent.
diff --git a/agents/plugins/smart b/agents/plugins/smart
index 404403f..0779c49 100755
--- a/agents/plugins/smart
+++ b/agents/plugins/smart
@@ -34,9 +34,9 @@ megaraid_info()
#PDINFO=$(MegaCli -PDlist -a0)
if [ -z "$1" ]; then
- PDINFO=$(megacli -PDlist -a0)
+ PDINFO=$(megacli -PDlist -a0 -NoLog)
else
- PDINFO=$($1 -PDlist -a0)
+ PDINFO=$($1 -PDlist -a0 -NoLog)
fi
echo "$PDINFO" | \