summaryrefslogtreecommitdiff
path: root/sysutils/munin-node
diff options
context:
space:
mode:
authorhe <he@pkgsrc.org>2008-10-15 13:13:09 +0000
committerhe <he@pkgsrc.org>2008-10-15 13:13:09 +0000
commitba9f8bf55054171df1d221bf488dec102d6b3ea5 (patch)
treec62753b83653e7439be3430a042c24d509969fb7 /sysutils/munin-node
parentfa020e71c064d8548dedc1699672cdc567421685 (diff)
downloadpkgsrc-ba9f8bf55054171df1d221bf488dec102d6b3ea5.tar.gz
Convert from using an input-less awk job (how did that ever work?)
to using shell arithmetic, which should be more light-weight and should not pose a danger of hanging.
Diffstat (limited to 'sysutils/munin-node')
-rw-r--r--sysutils/munin-node/Makefile3
-rwxr-xr-xsysutils/munin-node/files/node/node.d.netbsd/open_files.in11
2 files changed, 9 insertions, 5 deletions
diff --git a/sysutils/munin-node/Makefile b/sysutils/munin-node/Makefile
index 2f80d87a03a..f830394d3ba 100644
--- a/sysutils/munin-node/Makefile
+++ b/sysutils/munin-node/Makefile
@@ -1,9 +1,10 @@
-# $NetBSD: Makefile,v 1.9 2007/07/04 20:55:00 jlam Exp $
+# $NetBSD: Makefile,v 1.10 2008/10/15 13:13:09 he Exp $
#
DISTNAME= munin_${VER}
VER= 1.3.2
PKGNAME= munin-node-${VER}
+PKGREVISION= 1
CATEGORIES= sysutils
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=munin/}
diff --git a/sysutils/munin-node/files/node/node.d.netbsd/open_files.in b/sysutils/munin-node/files/node/node.d.netbsd/open_files.in
index 5ed473ba126..f8d5349e838 100755
--- a/sysutils/munin-node/files/node/node.d.netbsd/open_files.in
+++ b/sysutils/munin-node/files/node/node.d.netbsd/open_files.in
@@ -8,6 +8,11 @@
# autoconf (optional - used by munin-config)
#
# $Log: open_files.in,v $
+# Revision 1.2 2008/10/15 13:13:09 he
+# Convert from using an input-less awk job (how did that ever work?)
+# to using shell arithmetic, which should be more light-weight and should
+# not pose a danger of hanging.
+#
# Revision 1.1.1.1 2006/06/04 20:53:57 he
# Import the client version of the Munin system monitoring/graphing
# tool -- project homepage is at http://munin.sourceforge.net/
@@ -67,10 +72,8 @@ if [ "$1" = "config" ]; then
echo 'max.label max open files'
echo 'max.info The maximum supported number of open files.'
- awk -v filemax=$filemax '{
- printf "used.warning %d\n", $filemax * 0.92;
- printf "used.critical %d\n", $filemax * 0.98;
-}'
+ echo "used.warning $(($filemax * 92/100))"
+ echo "used.critical $(($filemax * 98/100))"
exit 0
fi