check_rinetd.sh 194 B

12345678910
  1. #!/bin/sh
  2. count=`ps -fe |grep "rinetd" | grep -v "grep" | wc -l`
  3. if [ $count -lt 1 ]; then
  4. rinetd -c /etc/rinetd.conf
  5. echo "restart rinetd"
  6. exit -1
  7. else
  8. echo "yes"
  9. exit 0
  10. fi