首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 开发语言 > 编程 >

sersync起动/停止脚本

2012-10-13 
sersync启动/停止脚本#! /bin/bash##sersyncd#. /etc/rc.d/init.d/functionscase $1 instart)cd /usr/lo

sersync启动/停止脚本

#! /bin/bash  #  #sersyncd  #  . /etc/rc.d/init.d/functions  case "$1" in         start)         cd /usr/local/sersync         ./sersync2 -r -d          if [ $? -eq 0 ]                  then                   echo -e "Staring sersyncd      [  OK  ]"                 exit 0          fi          ;;          stop)          kill 'ps aux | grep sersync2 | grep -v grep | awk '{print $2}''          if [ $? -eq 0 ]                 then                   echo -e "Stopping sersyncd     [  OK  ]"                 exit 0          fi          ;;         status)          ps aux | grep sersync2 | grep -v grep          ;;  esac 

?

热点排行