VK Cloud logo
Updated at April 15, 2024   08:50 AM

Kube Prometheus Stack

Installing the addon

Several installation options are available for the addon.

Take into account the total maximum system requirements of addons that will be placed on groups of worker nodes. If necessary, perform manual scaling for groups of worker nodes or configure automatic scaling before install.

  1. Install the addon:

    1. Go to VK Cloud personal account.

    2. Select project, where the cluster will be placed.

    3. Go to ContainersKubernetes clusters.

    4. Click on the name of the desired cluster.

    5. Go to Addons tab.

    6. If there are already installed addons in the cluster, click on the Add addon button.

    7. Click the Install addon button on the kube-prometheus-stack addon card.

    8. Edit if necessary:

      • application name;

      • the name of the namespace where the addon will be installed;

      • addon settings code.

    9. Click the Install addon button.

      The installation of the addon in the cluster will begin. This process can take a long time.

  2. If necessary change the Prometheus disk size.

  3. If necessary get the password for Grafana from the Kubernetes secret.

Editing the addon setup code during installation

Setting a temporary password for the Grafana web interface

When installing an addon with default parameters, a Kubernetes secret will be created containing a permanent password to log in to the Grafana web interface.

Also, when installing the addon, you can specify a temporary user password. In this case, the first login to the Grafana web interface is performed with this password, then you will be prompted to change it. To do this, change the value of the field in the addon setup code:

grafana:  adminPassword: "<temporary user password>"

After editing the addon code continue installing the addon.

Changing the Prometheus disk size

This operation is available if the monitoring addon kube-prometheus-stack is installed in the cluster.

The Prometheus disk stores cluster monitoring data. If there is not enough space for them, or you want to increase the performance of the Prometheus disk, increase the disk size.

  1. Go to VK Cloud personal account.
  2. Select project, where the cluster will be placed.
  3. Go to ContainersKubernetes clusters.
  4. Click on the name of the desired cluster.
  5. Go to Addons tab.
  6. Expand the kube-prometheus-stack addon menu and choose option Change Prometheus disk size.
  7. Set the desired disk size. The operation works only in the direction of increase.
  8. Click the Confirm button.

Getting the password for Grafana from the Kubernetes secret

If the addon was installed without specifying a temporary password, the password value for entering the Grafana web interface can be obtained from the Kubernetes secret.

  1. Connect to the cluster via Kubernetes Dashboard.

  2. In the drop-down list next to the left of the search bar, select a namespace prometheus-monitoring.

  3. Go to Config and Storage → Secrets.

  4. Find kube-prometheus-stack-grafana in the list of secrets and click on the secret name.

  5. In the Data block, click on the eye icon next to the admin-password parameter.

    The password will be displayed.