Module: check_mk
Branch: master
Commit: b06e6fda0b59e4c3d97a1f2c2681d9cafc6070f0
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=b06e6fda0b59e4…
Author: Marcel Arentz <ma(a)mathias-kettner.de>
Date: Tue Feb 28 09:32:42 2017 +0100
4439 statgrab: added uptime into plugin
Added uptime section to statgrab plugin so HP-UX Hosts are now reporting
this section. You need to have the hpux_statgrab plugin installed to profit
from this update.
Change-Id: Id2544be3ab581b7392eed2022f0fc0501e6fd938
---
.werks/4439 | 12 ++++++++++++
agents/plugins/hpux_statgrab | 3 +++
2 files changed, 15 insertions(+)
diff --git a/.werks/4439 b/.werks/4439
new file mode 100644
index 0000000..9df0a3f
--- /dev/null
+++ b/.werks/4439
@@ -0,0 +1,12 @@
+Title: statgrab: added uptime into plugin
+Level: 1
+Component: checks
+Compatible: compat
+Edition: cre
+Version: 1.5.0i1
+Date: 1488270599
+Class: feature
+
+Added uptime section to statgrab plugin so HP-UX Hosts are now reporting
+this section. You need to have the hpux_statgrab plugin installed to profit
+from this update.
diff --git a/agents/plugins/hpux_statgrab b/agents/plugins/hpux_statgrab
index 3f47a6f..c592ff1 100755
--- a/agents/plugins/hpux_statgrab
+++ b/agents/plugins/hpux_statgrab
@@ -41,6 +41,9 @@ if which statgrab > /dev/null ; then
echo '<<<statgrab_mem>>>'
cat /tmp/statgrab.$$ | egrep "^(swap|mem)\." | sed 's/ *= */
/'
+ echo '<<<uptime>>>'
+ cat /tmp/statgrab.$$ | egrep "^general\.uptime" | sed 's/.*
//'
+
fi
[ -f /tmp/statgrab.$$ ] && rm -f /tmp/statgrab.$$
fi