How to setup an alert for a failing livesness probe in kubernetes

Hi all,

I installed metricbeats on kubernetes as explained here and get now a nice dashboard of the kubernetes status.
In kubernetes i use liveness probes to see if a pod is down.
Now i want to get alerted if liveness probes don't have success and the deployment of my microservice has problems.
How can i get alerted that there is a problem with the liveness of my pods.
If not what can be he alternative? I want to get alerted when my pods have problems. I am sure that metricbeats has all the data i need.

Thanks,

Hi @David_Michael_Gang,

You have this information in the following fields:
kubernetes.pod.status.phase and kubernetes.pod.status.ready, reported by state_pod metricset. If you have configured Metricbeat using our manifests along with kube-state-metrics it should be already working.

Phase and stauts are explained here:

In general you are probably looking to alert when kubernetes.pod.status.phase is pending or failed.

You can define alerts with Watcher, have a look to https://www.elastic.co/guide/en/x-pack/current/watcher-getting-started.html to deploy it, and https://www.elastic.co/guide/en/kibana/current/watcher-getting-started.html for a nice UI to configure
alerts.

Best regards

1 Like

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.