title: How to check solr server restarted sucessfully or not?
body: <p>I am writing an automate script, where I am restarting solr servers one by one. But some time they are not restarting.</p>
  
  <p>I am using the below command to restart it:</p>
  
  <pre><code>stopsolr; //stoping the solar server
  cd $SolrFolder; //going to index folder
  unzip -o $solrindex; //extracting the index
  sleep 240; //waiting some time
  startsolr" &gt;&gt; $SolrLog;//starting server
  </code></pre>
  
  <p>Now I want to check if the server started or not. If not started, then I want to stop my script from execution and will return an error code. I am vary new to Linux environment/shell scripting. Which command I can use to check the status of solr server?</p>