#!/bin/bash
sleep=1
echo psr|tmadmin > tmadmin.txt 2>&1
echo "\$_MONITOR_RESPONSE_\$"
ser1=`cat tmadmin.txt | grep simpserx`
if [ $? = 0 ];then
printf "simpserx:1 "
else
printf "simpserx:0 "
fi
ser2=`cat tmadmin.txt | grep simpsera`
if [ $? = 0 ];then
printf "simpsera:1 "
else
printf "simpsera:0 "
fi
ser3=`cat tmadmin.txt | grep server1`
if [ $? = 0 ];then
echo "server1:1"
else
echo "server1:0"
fi