title: Shell Script For Process Monitoring
body: <p>This</p>
  
  <pre><code>#!/bin/bash
  if [ `ps -ef | grep "91.34.124.35" | grep -v grep | wc -l` -eq 0 ]; then sh home/asfd.sh; fi
  </code></pre>
  
  <p>or this?</p>
  
  <pre><code>ps -ef | grep "91\.34\.124\.35" | grep -v grep &gt; /dev/null
  if [  "$?" -ne "0" ]
  then
  sh home/asfd.sh
  else
  echo "Process is running fine"
  fi
  </code></pre>
  
  <p>Hello, how can I write a shell script that looks in running processes and if there isn't a process name <strong>CONTAINING</strong> 91.34.124.35 then execute a file in a certain place and I want to make this run every 30 seconds in a continuous loop, I think there was a sleep command. </p>