From 9388f9494f5089f9e6e0ff267e742ca6acac20bc Mon Sep 17 00:00:00 2001 From: Subhendu Ghosh Date: Thu, 6 Jun 2002 04:14:06 +0000 Subject: conditional on lmstat git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@44 f882894a-f735-0410-b71e-b25c423dba1c --- plugins-scripts/check_flexlm.pl | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/plugins-scripts/check_flexlm.pl b/plugins-scripts/check_flexlm.pl index 6bda29bd..0f7ab6e8 100755 --- a/plugins-scripts/check_flexlm.pl +++ b/plugins-scripts/check_flexlm.pl @@ -1,4 +1,4 @@ -#! /usr/bin/perl -wT +#! /usr/bin/perl -w # # usage: # check_flexlm.pl license_file @@ -66,7 +66,11 @@ $SIG{'ALRM'} = sub { }; alarm($TIMEOUT); -my $lmstat = "/opt/lic/sw/cadadm/default/bin/lmstat"; +my $lmstat = $utils::PATH_TO_LMSTAT ; +unless (-x $lmstat ) { + print "Cannot find \"lmstat\"\n"; + exit $ERRORS{'UNKNOWN'}; +} ($opt_F) || ($opt_F = shift) || usage("License file not specified\n"); my $licfile = $1 if ($opt_F =~ /^(.*)$/); -- cgit v1.2.3