Get the App
SLTechnology News&Howtos  ›  Servers  › 

Monitoring kubetnetes clusters using Prometheus Operator

Shulou Source: shulou.com Published: 2022-06-02 04:09:15 11月15日 Update

A brief introduction to Prometheus

Prometheus is an open source monitoring system, which has become the de facto standard for monitoring indicators in cloud native. Almost all the core components of Kubernetes and other cloud native systems output their own runtime monitoring information in the format of Prometheus indicators.

Main features:

A multi-dimensional data model identified by indicator names and key-value pairs. The flexible query language PromQL is adopted. It does not rely on distributed storage and serves an autonomous single point. Use http to complete the pull of monitoring data. The push of timing data is supported through the gateway. Support a variety of graphics and Dashboard display.

In addition, there are a variety of optional components in the entire ecosystem of Prometheus for functional expansion.

Prometheus-Operator

CoreOS provides an administrative tool called Operator, which is the controller that manages specific applications. Extend Kubernetes API to help users create, configure and manage complex or stateful application instances (such as etcd, Redis, MySQL, Prometheus, etc.) in a software way.

It deploys and configures the services that Prometheus and Prometheus need to monitor through Kubernetes's CRD (Custom Resource Definition, custom resource definition).

Prometheus-Operator uses the following two resources to configure Prometheus and the services it monitors.

Prometheus: the deployment of Prometheus. ServiceMonitor: used to describe the services monitored by Prometheus.

First, let's take a look at the architecture diagram of Prometheus-Operator:

When the browser accesses grafana http://grafana.cnlinux.club/, you can see the monitoring charts of various resources.

The user name is admin and the password is the password specified in the values.yaml configuration file

Browsers access Alertmanager

Http://alert.cnlinux.club/, you can see the alarm item.

Now that all installation is complete, the next article will detail the use of prometheus to monitor custom services, as well as alarm settings. If you have any questions, please leave a message below. I hope you will pay more attention and like it. Thank you!

Tags: Configuration monitoring files data resources services that is status environment reference object directory system certificate cluster name password metric label browser Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Microsoft macOS NVidia Shulou Tech Info MySQL