title: How to include 4 more JVM instances?
body: <p>I want to include 4 more JVMs to check logs are exiting or not and also want include those 4 More jvms to pull logs to path, as per below script. How can I modify the script which can used for multiple JVM?</p>
  
  <pre><code>#!/bin/bash
  Minute=$(expr `date +%M` - 15)
  Hour=$(expr `date +%H`)
  Current_Time=$(date +%d/%b/%Y:%H:%M:%S)
  f=$(find /apps_01/webapps/JBoss/logs/xxxx JVM1_server*/http_logs/ -name  access_log.`date +%Y-%m-%d`.log |wc -l)
  if [ "$f" -gt 0 ]
  then
  tail -500 /apps_01/webapps/JBoss/logs/xxxx JVM1_server*/http_logs/access_log.`date +%Y-%m-%d`.log|awk '{print $4}'| cut -d '[' -f2 &gt;&gt; /home/tmp/xxx_logs
  h=$(awk -F'[: ]' '{print $2}' /home/tmp/xxx_logs|tail -1)
  if [ "$h" -ge "$Hour" ]
  then
  for m in `awk -F'[: ]' '{print $3}' /home/tmp/xxx_logs`
  do
  if [ "$m" -ge "$Minute" ]
  then
  echo $m
  fi
  done
  fi
  fi
  </code></pre>