Module: check_mk
Branch: master
Commit: bf657f6fa92ece65647ed74911c974ac330a1a91
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=bf657f6fa92eceā¦
Author: Simon Betz <si(a)mathias-kettner.de>
Date: Tue Jun 21 10:13:39 2016 +0200
added additional fixes for zfs_arc_cache
---
agents/check_mk_agent.solaris | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/agents/check_mk_agent.solaris b/agents/check_mk_agent.solaris
index d370448..cf1d3ca 100755
--- a/agents/check_mk_agent.solaris
+++ b/agents/check_mk_agent.solaris
@@ -193,7 +193,8 @@ fi
# ZFS arc cache
# newer Solaris (>=11.3) do not provide hits and misses via mdb -k
function get_zfs_arc_cache_data () {
- if [ ! -z `echo "::arc" | mdb -k | grep -q "hits"` ]
+ out=$(echo "::arc" | mdb -k | grep "hits")
+ if [ ! -z "$out" ]
then
echo "::arc" | mdb -k
else