#!/bin/bash while :do ps -C vpxd --no-header >/dev/null 2>&1 if [ $? -eq 1 ];then /etc/init.d/vmware-vpxd start fi sleep 5 donebash