[mrtg] Re: ThreshProgI requirement

Ni Patrick-A11024 Patrick.Ni at motorola.com
Wed Jan 24 00:09:58 MET 2001


Hi,

  I have fixed it. My environment is Solaris 2.6 on Sun Ultra 5. My 
MRTG is 2.9.7.

  1. No single quote mark around the script path name. It should be
     ThreshProgI[anvil-net18.ping]: /local/mrtg/bin/test, instead of
     ThreshProgI[anvil-net18.ping]: `/local/mrtg/bin/test`

  2. It seems that MRTG expects a PERL script. So my external program
     which is to be triggered when threshold is broken is encapsulated
     (covered or enveloped) under Perl script.

   Cheers.

Patrick 

-----Original Message-----
From: Ni Patrick-A11024 [mailto:Patrick_Ni-A11024 at email.mot.com]
Sent: Monday, January 22, 2001 9:24 PM
To: mrtg at list.ee.ethz.ch
Subject: [mrtg] ThreshProgI requirement


Hi,

  I keep getting the following error message:
  ERROR: CFG Error in "threshprogi[anvil-net18.ping]", line 0: Threshold program
`/local/mrtg/bin/test` cannot be executed

  At the end of this email, is the "test" program and "ping.cfg" file. I am not
sure whethere there is any requirment on the external script to be trigged.

  Please advise. Thanks.






================================================

#! /usr/bin/perl

require 5.6.0;

use lib "/local/mrtg/lib/mrtg2";

use SNMP_util "0.77";


sub main {

    @args = ("mailx -s bad  pni < /dev/null");
    system @args;

}

main;
exit 0;
=======================================



Workdir: /local/apache-1.3.12/htdocs/mrtg/ping

Forks: 4
WriteExpires: Yes
Refresh: 300
#interval: 10

Target[anvil-net18.ping]: `/local/mrtg-ping-probe/mrtg-ping-probe -s -k 10 -l 56 -o -n anvil-net18` 
MaxBytes[anvil-net18.ping]: 20
AbsMax[anvil-net18.ping]: 50
Options[anvil-net18.ping]: gauge,nopercent
Title[anvil-net18.ping]: Ping response time (round trip) for anvil-net18
PageTop[anvil-net18.ping]: <H1>Ping response time (round trip) for anvil-net18</H1>
YLegend[anvil-net18.ping]: Round Trip Time
ShortLegend[anvil-net18.ping]: ms
Legend1[anvil-net18.ping]: Maximum Round Trip Time in ms
Legend2[anvil-net18.ping]: Minimum Round Trip Time in ms
Legend3[anvil-net18.ping]: Maxmimal 5 Minute Maxmum Round Trip Time in ms
Legend4[anvil-net18.ping]: Maxmimal 5 Minute Minimum Round Trip Time in ms
LegendI[anvil-net18.ping]: &nbsp;Max:
LegendO[anvil-net18.ping]: &nbsp;Min:
WithPeak[anvil-net18.ping]: ymwd
ThreshMinI[anvil-net18.ping]: 1
ThreshMaxI[anvil-net18.ping]: 5
ThreshProgI[anvil-net18.ping]: `/local/mrtg/bin/test`
=====================================================

Patrick Ni
ITS UNIX System Administrator
Motorola Vancouver
11411, No. 5 Road, Richmond, B.C., Canada V7A4Z3

Tel: 604-241-6085 
Fax: 604-241-6042 
Cell: 604-719-2781
Email: Patrick.Ni at Motorola.com



--
Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
Archive     http://www.ee.ethz.ch/~slist/mrtg
FAQ         http://faq.mrtg.org    Homepage     http://www.mrtg.org
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi


--
Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
Archive     http://www.ee.ethz.ch/~slist/mrtg
FAQ         http://faq.mrtg.org    Homepage     http://www.mrtg.org
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi



More information about the mrtg mailing list