Displaying 1 result from an estimated 1 matches for "ascal".
Did you mean:
pascal
2013 Feb 16
1
Asterisk not return int value
Hello Everyone,
I have write a script following script for nagios
-- typeset -i CRITICAL;
#Positional parameter
CRITICAL=`echo $2`;
ME=`basename $0`;
#echo $CRITICAL
if [[ "$2" == "" ]]
then
echo NO INPUT!!! Usage ./$ME -c N
else
typeset -i ASCALLS;
ASCALLS=`asterisk -rx "core show channels" | grep active | grep call | awk
'{print $1}'`
#echo $ASCALLS;
#mload=`echo "$ASCALLS" | $BC`;
#echo $((num+1))
if [[ "$ASCALLS" -lt "$CRITICAL" ]]
then
echo OK!!! Total Active Call...