From e803e46a50ab50ba85af0dc87e6971f5f4c8b4b0 Mon Sep 17 00:00:00 2001 From: Sec Date: Mon, 18 Oct 2010 12:54:59 +0200 Subject: [PATCH] Initial version --- plugins/other/uptime_bsd | 58 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100755 plugins/other/uptime_bsd diff --git a/plugins/other/uptime_bsd b/plugins/other/uptime_bsd new file mode 100755 index 00000000..c0f8f20c --- /dev/null +++ b/plugins/other/uptime_bsd @@ -0,0 +1,58 @@ +#!/usr/local/bin/perl -w +# -*- perl -*- +# Plugin to monitor number of irqs +# +#%# family=auto +#%# capabilities=autoconf + +use strict; + +my %IN; + +my $sysctl = defined($ENV{sysctl}) ? $ENV{sysctl} : '/sbin/sysctl'; + +if (defined($ARGV[0]) and ($ARGV[0] eq 'autoconf')) { + if ( -x $sysctl ) { + print "yes\n"; + }else{ + print "no (sysctl binary not found)\n"; + }; + exit; +}; + +if (defined($ARGV[0]) and ($ARGV[0] eq 'config')) { +print <