Hi
I'll try again to post a message in hope this time i get lucky.
I'm trying ti send sms from hobbit with this hobbit-alerts.cfg: HOST=dkcphodbfi01.dk.carlbro.net SERVICE=oracle,cpu SCRIPT /usr/lib/hobbit/server/ext/lbj 4520883616 REPEAT=1h TIME=*:1000:2200 COLOR=red
HOST=apollo.consit.dk TIME=*:0800:2200 SERVICE=oracle,cpu,disk,memory SCRIPT /usr/local/bin/sendsms 4520883616 "$BBALPHAMSG" REPEAT=24h COLOR=red FORMAT=sms
neither of them are working. I have tried several different setup's but none of them are working.
I get nog errors in notification.log or page.log. when i do:
./bin/bbcmd hobbitd_alert --debug --test HOSTNAME oracle 2010-02-15 13:19:36 Using default environment file /usr/lib/hobbit/server/etc/hobbitserver.cfg 2010-02-15 13:19:36 Opening file /usr/lib/hobbit/server/etc/bb-hosts 2010-02-15 13:19:36 Opening file /usr/lib/hobbit/server/etc/hobbit-alerts.cfg 2010-02-15 13:19:36 send_alert hostname:oracle state 0 00028236 2010-02-15 13:19:36 send_alert hostname:oracle state Paging 00028236 2010-02-15 13:19:36 Matching host:service:page 'hostname:kunder/page' against rule line 126 00028236 2010-02-15 13:19:36 *** Match with 'HOST=hostname SERVICE=oracle,cpu' *** 2010-02-15 13:19:36 Found a first matching rule 00028236 2010-02-15 13:19:36 Matching host:service:page 'hostname:oracle:kunder/page' against rule line 127 2010-02-15 13:19:36 start,end,current time = 600, 1320, 799 - found=1 00028236 2010-02-15 13:19:36 *** Match with 'SCRIPT /usr/lib/hobbit/server/ext/lbj 4520883616 REPEAT=1h TIME=*:1000:2200 COLOR=red' *** 2010-02-15 13:19:36 repeat hostname|oracle|script|4520883616 at 0 2010-02-15 13:19:36 Alert for hostname:oracle to 4520883616 00028236 2010-02-15 13:19:36 Script alert with command '/usr/lib/hobbit/server/ext/lbj' and recipient 4520883616 00028236 2010-02-15 13:19:36 Matching host:service:page 'hostname:oracle:kunder/page' against rule line 129 2010-02-15 13:19:36 No more secondary matching rule
here's my lbj.sh: #!/bin/sh
#set -vx #debug on:: #echo "/usr/local/bin/sendsms $RCPT $BBALPHAMSG $ACKCODE" >> /tmp/smsd.log
/usr/local/bin/sendsms $RCPT "$BBALPHAMSG $ACKCODE"
i have also tried smsplus.sh: #!/bin/bash
msg=echo "${BBALPHAMSG}" | egrep "&yellow|&red"
msg="\n${msg}"
CODE:
#======= subject="!HB ${ACKCODE}" alert="${BBHOSTSVC} ${BBCOLORLEVEL}" message="\n${alert}${msg}"
echo -e "${message}" | mail -s "${subject}" $RCPT
with same luck.
I think i need something in my hobbit-alerts.cfg file, but i don't know what it is. It could be the RCPT variable, but i dont know where to post it.
Hope one of you can help me.
I have posted the same problem here: http://www.hswn.dk/hobbiton/2010/01/msg00103.html
Kind regards Lars Baad-Jensen
__________ Information from ESET Smart Security, version of virus signature database 4867 (20100215) __________
The message was checked by ESET Smart Security.
participants (1)
-
lars@baad-jensen.dk