#!/bin/bash GW=`ps -lef | grep GW | grep -v "grep"` if [$GW -eq ""];then echo "no runing" nohup /usr/local/gateway/yunhorn-gw/run_scripts/do.sh & echo "start GW" else echo "GW is runing" fi