Added basic utilities.

This commit is contained in:
Ciaby 2014-07-14 14:23:00 -05:00
parent f55f4d699d
commit 84475594cc
8 changed files with 113 additions and 19 deletions

View file

@ -0,0 +1,13 @@
#!/bin/bash
. ./vars.sh
while (true);
do STR=`echo "show lchan" | nc localhost 4242 | grep BROKEN`;
if [ -n "$STR" ];
then echo `date "+%y%m%d_%H%M"` >> /var/tmp/broken_channels_log.txt;
STR=`echo "show lchan" | nc localhost 4242`;
echo -e "Subject:BROKEN Channels\n\nBroken at: `date`\n\n\n$STR" | sendmail $RECIPIENTS
fi;
sleep 600;
done