pts stop rep script echo bash scrip else etc
#! /bin/bash
if [
netstat - tnlup | grep nginx | wc - l
-gt 0 ];then
echo "Nginx is running."
else
echo "Nginx is stopped."
/etc/init.d/nginx start
fi
check Nginx running scripts
来源: http://www.bubuko.com/infodetail-2463317.html