-------- Original Message --------
Subject: Re: getting mon to execute shell command
Date: Sun, 25 Apr 2010 20:06:22 +0200
From: <ad...@jack-clan.nl>
To: "Mahlon E. Smith" <mah...@martini.nu>

Pffft nope still not working,

i tested the script by executing ./sms.alert, and that works ok....

sms.alert:


#!/bin/sh

echo "servers down test" | /usr/bin/gammu --sendsms TEXT 0612345678

mon.cf:

alertdir   = /usr/lib/mon/alert.d
mondir     = /usr/lib/mon/mon.d
logdir     = /var/log/mon
histlength = 100


dtlogging   = yes
dtlogfile   = dtlog

hostgroup domain
        domain.org

watch domain
        service tcp
                interval 1m
                monitor tcp.monitor -p 16001
                period
                        numalerts 2
                        alert sms.alert
                        upalert sms.alert






On Sun, 25 Apr 2010 10:38:00 -0700, "Mahlon E. Smith" <mah...@martini.nu>
wrote:
> On Sun, Apr 25, 2010, ad...@jack-clan.nl wrote:
>> 
>> I changed the test.alert script so it reads this:
>> 
>>  #!/usr/bin/sh
>> 
>> echo "servers down test" | gammu --sendsms TEXT 0653638072
>> 
>> But it doesn't work....
> 
> 
> Have you tried running that script yourself?  (Not the contents, but the
> script itself.)
> 
> I don't know of any OS that stores sh in /usr/bin.  My bet is on
> /bin/sh.  :)
> 
> --
> Mahlon E. Smith  
> http://www.martini.nu/contact.html

_______________________________________________
mon mailing list
mon@linux.kernel.org
http://linux.kernel.org/mailman/listinfo/mon

Reply via email to