title: How to verify if nginx is running or not?
body: <p>After <a href="http://xameeramir.github.io/asp-net-5-ubuntu-linux/" rel="noreferrer">running an ASP.NET vNext project</a> on my local machine I was trying to figure out how I can run it on <a href="https://www.nginx.com/" rel="noreferrer">nginx</a> as it looks to be a <a href="https://docs.asp.net/en/latest/fundamentals/servers.html#choosing-a-server" rel="noreferrer">recommended choice</a> </p>
  
  <p>Following <a href="https://stackoverflow.com/users/376196/jsinh">jsinh's</a> <a href="http://blog.jsinh.in/hosting-asp-net-5-web-application-on-linux/" rel="noreferrer">blog</a>, I installed it using:</p>
  
  <pre><code>sudo apt-get update
  sudo apt-get install nginx -y
  </code></pre>
  
  <p>I was trying to understand whether it is working or not by using:</p>
  
  <pre><code>ifconfig eth0 | grep inet | awk '{ print $2}'
  </code></pre>
  
  <p>After running </p>
  
  <pre><code>sudo service nginx start
  sudo service nginx stop
  </code></pre>
  
  <p>However, the output is always the same:</p>
  
  <p><a href="https://i.stack.imgur.com/VXHlX.png" rel="noreferrer"><img src="https://i.stack.imgur.com/VXHlX.png" alt="Nginx status"></a></p>
  
  <blockquote>
    <p>How to verify if nginx is running or not?</p>
  </blockquote>