Well,It is just a small problem to solve,i have one shell script and i wanna make it work on my server,i have tried but wont work,i puted on root directory but it only return value "0" and doesnt turn on the server,i wanna run multiples server in each folder but of course with name differents samp1,samp2,samp3...this script is added on cronjob and run everyminute to check if the server is turned on and if not i will run
the script code is
PROCESS_COUNT=$(ps aux | grep samp1 | grep -v grep | wc -l)
case $PROCESS_COUNT in
0) /root/samp1/samp1 &
1) echo "OK, program is already running once"
*) echo "OK, program is already multiple times"
Well if you think this script is not good,you can build one improved
My system is Centos 5,Running on VPS
I wanna just the script installed and working in 2 VPS,i will give shell acess,ftp or what needed