Use Blackbox Exporter for HTTP Status Checks using Prometheus and Grafana
AWS | Azure | Endpoint Check | Kubernetes
In this article, we will be utilizing the Blackbox Exporter within Prometheus to obtain HTTP status updates of endpoints. This article does assume that you have an installed version of Prometheus, a Kubernetes (K8s) cluster, as well as Grafana already instead.
What is Blackbox Exporter?
The Blackbox Exporter is a tool that we can utilize to probe (aka test) the status of endpoints. The probe can analyze the endpoints over HTTP, HTTPS, DNS, TCP, and ICMP. In this article, we will be utilizing the HTTP (aka http_2xx) module to test for 200 status checks.
Creating the Blackbox Exporter
Namespace Creation
- We first need to create the namespace that we will add to the Blackbox Exporter. Please note, Prometheus is installed in the βmonitoringβ namespace. If you have Prometheus installed in a different namespace, then you can move forward to the next step.
Run the following to create a namespace called monitoring:
kubectl create ns monitoring
2. Creating the Config Map used by Blackbox. Run the following Yaml file: