> For the complete documentation index, see [llms.txt](https://utm-1.gitbook.io/utm-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://utm-1.gitbook.io/utm-docs/dokumentaciya/utm-it/resheniya/monitoring/prometheus/monitoring-redis.md).

# Мониторинг Redis

## Ссылки

Мониторинг Redis с помощью Redis Exporter: [arenda-server.cloud](https://arenda-server.cloud/blog/monitoring-redis-s-pomoshhju-redis-exporter/)

oliver006 / redis\_exporter: [github.com](https://github.com/oliver006/redis_exporter)

## Установка Redis exporter

Описано [тут](/utm-docs/dokumentaciya/utm-it/resheniya/subd/postgres/instansy/utm-postgres18-na-utm-db4-9.md#zapusk-docker-konteinera-s-postgres-exporter)

## Настройка Prometheus

### Регистрация target

В файле `argocd\env-prod\apps\monitoring\prometheus\values.yaml`&#x20;

<details>

<summary>Изменения в файле <code>argocd\env-prod\apps\monitoring\prometheus\values.yaml</code></summary>

Добавить ip сервера в секцию&#x20;

prometheus\prometheusSpec\additionalScrapeConfigs

```yaml
    additionalScrapeConfigs: |
      - job_name: 'redis_exporter'
        static_configs:
          - targets:
            - 192.168.4.9:9121
            - <ip>:9121
```

Сделать коммит в репозиторий GitHub с обновлением файла `values.yaml`&#x20;

Дождаться, когда Argo CD обновить приложение k8s-prometheus.

</details>

### Настройка оповещений

{% hint style="info" %}
**ПРОРАБОТАТЬ!!!**
{% endhint %}

## Настройка Grafana

### Импорт дашбордов из Argo CD

В файле `argocd\env-prod\apps\monitoring\grafana\values.yaml` добавить

<details>

<summary>Изменения в файле <code>argocd\env-prod\apps\monitoring\grafana\values.yaml</code></summary>

```yaml
dashboardProviders:
  dashboardproviders4.yaml:
    apiVersion: 1
    providers:
    - name: 'redis'
      orgId: 1
      folder: 'Redis'
      type: file
      disableDeletion: false
      editable: true
      options:
        path: /var/lib/grafana/dashboards/redis
        foldersFromFilesStructure: false

dashboards:
  redis: {}
```

Сделать коммит в репозиторий GitHub с обновлением файла `values.yaml`&#x20;

Дождаться, когда Argo CD обновить приложение k8s-grafana.

</details>

#### Дашборды

<details>

<summary>Описание импортируемых дашбордов</summary>

Пока нет

</details>

### Ручной импорт дашбордов

В Grafana: Dashboards → Import → вставь ID  → выбери источник Prometheus.

Каталог в дашбордах: `Redis`

#### Дашборды

<details>

<summary>Описание импортируемых дашбордов</summary>

#### Redis Dashboard for Prometheus Redis Exporter 1.x

Ссылка: [grafana.com](https://grafana.com/grafana/dashboards/763-redis-dashboard-for-prometheus-redis-exporter-1-x/)

ID: 763

<figure><img src="/files/XrTdgLkW5RyYU5cSR3By" alt=""><figcaption></figcaption></figure>

</details>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://utm-1.gitbook.io/utm-docs/dokumentaciya/utm-it/resheniya/monitoring/prometheus/monitoring-redis.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
