Answers: <blockquote>
    <p>I've looked a bit at Consul and Prometheus and am thinking that that is the way forward?</p>
  </blockquote>
  
  <p>In short, yes.</p>
  
  <p>Consul is designed exactly for this - it will run health checks against all of your services that you define and can detect when things go down. However, what it does not do it alert when things do go down, it is more designed for automatically taking things out of circulation when they are unhealthy. But it does give you a single point you can query for the health of your infrastructure which you can then alert on manually somehow or combine it with <a href="https://github.com/AcalephStorage/consul-alerts" rel="noreferrer">consul-alerts</a> to do this for you.</p>
  
  <p>Prometheus is geared towards metrics and can monitor the health of your applications in ways that consul is not really well suited. It has its only able to alert when defined events occur and you can tune it to monitor exactly what you require.</p>
  
  <p>You might also want to consider external checks like what services such as <a href="https://www.panopta.com/" rel="noreferrer">panopta</a> offer  (this is just an example, there are many alternatives out there) to check public endpoints to make sure they are still working from an external perspective.</p>
  
Answers: CC BY-SA 3.0
Answers: 2018-02-13T13:14:38.763Z
Answers: 2018-02-13T13:14:38.763Z
Answers: Michael Daffin
Body: <p>Currently I am using the HashiCorp stack (Packer, Terraform) and Ansible, to generate Immutable Infrastructure and Infrastructure as Code.</p>
  
  <p>This builds a Virtual Machine from a base image, provisions it and applies it to some VSphere servers.</p>
  
  <p>One of the issues I'm having is knowing when a VM is down or unresponsive.</p>
  
  <p>What would be a good way of monitoring VMs?</p>
  
  <p>I've looked a bit at Consul and Prometheus and am thinking that that is the way forward?</p>
  
Tags: <monitoring><immutable-servers>
Title: Monitoring immutable infrastructure virtual machines
UserDisplayName: Rekovni
ThreadText: # Monitoring immutable infrastructure virtual machines
  
  (Asked by: username_0 on 2018-02-13)
  
  Currently I am using the HashiCorp stack (Packer, Terraform) and Ansible, to generate Immutable Infrastructure and Infrastructure as Code.
  
  This builds a Virtual Machine from a base image, provisions it and applies it to some VSphere servers.
  
  One of the issues I'm having is knowing when a VM is down or unresponsive.
  
  What would be a good way of monitoring VMs?
  
  I've looked a bit at Consul and Prometheus and am thinking that that is the way forward?
  
  **Tags:** monitoring, immutable-servers
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2018-02-13. Score: 5 | Accepted answer
  
  > I've looked a bit at Consul and Prometheus and am thinking that that is the way forward?
  
  In short, yes.
  
  Consul is designed exactly for this - it will run health checks against all of your services that you define and can detect when things go down. However, what it does not do it alert when things do go down, it is more designed for automatically taking things out of circulation when they are unhealthy. But it does give you a single point you can query for the health of your infrastructure which you can then alert on manually somehow or combine it with [consul-alerts](https://github.com/AcalephStorage/consul-alerts) to do this for you.
  
  Prometheus is geared towards metrics and can monitor the health of your applications in ways that consul is not really well suited. It has its only able to alert when defined events occur and you can tune it to monitor exactly what you require.
  
  You might also want to consider external checks like what services such as [panopta](https://www.panopta.com/) offer (this is just an example, there are many alternatives out there) to check public endpoints to make sure they are still working from an external perspective.
  
  
  ---
  
  