In a nutshell, the following image depicts what we are going to build. The Kubernetes Prometheus monitoring stack has the following components. If you would like to install Prometheus on a Linux VM, please see the Prometheus on Linux guide. Here is the high-level architecture of Prometheus. However, to avoid single point of failure, there are options to integrate remote storage for Prometheus TSDB. By default, all the data gets stored locally. TSDB (time-series database): Prometheus uses TSDB for storing all the data efficiently.It exposes all Linux system-level metrics in Prometheus format. One example is, Prometheus node exporter. There are many official and community Prometheus exporters. Prometheus Exporters: Exporters are libraries which converts existing metric from third-party apps to Prometheus metrics format.Also, the PromQL query will be used by Prometheus UI and Grafana to visualize metrics. PromQL: Prometheus comes with PromQL, a very flexible query language that can be used to query the metrics in the Prometheus dashboard.Prometheus uses this endpoint to pull the metrics in regular intervals. Metric Endpoint: The systems that you want to monitor using Prometheus should expose the metrics on an /metrics endpoint.One such example is collecting custom metrics from short-lived kubernetes jobs & Cronjobs
There is an option to push metrics to Prometheus using Pushgateway for use cases where Prometheus cannot Scrape the metrics. Metric Collection: Prometheus uses the pull model to retrieve metrics over HTTP.However, there are a few key points I would like to list for your reference. If you want to know more about Prometheus, You can watch all the Prometheus-related videos from here. It provides out-of-the-box monitoring capabilities for the Kubernetes container orchestration platform.Įxplaining Prometheus is out of the scope of this article. Prometheus is an open-source monitoring framework. This setup collects node, pods, and services metrics automatically using Prometheus service discovery configurations. This Prometheus kubernetes tutorial will guide you through setting up Prometheus on a Kubernetes cluster for monitoring the Kubernetes cluster.