# Monitoring Valkey and Redis with PMM

**URL:** <https://forums.percona.com/t/monitoring-valkey-and-redis-with-pmm/35700>\
**Category:** Valkey & Redis\
**Created:** [December 17, 2024, 9:05am UTC](https://forums.percona.com/t/monitoring-valkey-and-redis-with-pmm/35700 "2024-12-17T09:05:38Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![daniil.bazhenov](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/daniil.bazhenov/32/62_2.png) [@daniil.bazhenov](https://forums.percona.com/u/daniil.bazhenov)\
**Post date:** [December 17, 2024, 9:05am UTC](https://forums.percona.com/t/monitoring-valkey-and-redis-with-pmm/35700/1 "2024-12-17T09:05:38Z")

</div>

I recently shared a story about an [application](https://forums.percona.com/t/demo-application-for-load-to-mysql-postgres-mongodb-databases-is-developed-with-valkey/35687) that uses Valkey

The application uses PMM to monitor MySQL, Postgres, MongoDB databases.

Today I tried to add Valkey monitoring.

I used the PMM documentation to add an external metrics service.

> **[Percona Monitoring and Management - External Services](https://docs.percona.com/percona-monitoring-and-management/setting-up/client/external.html)**
>
> Documentation

I also found the blog post helpful.

> **[How to Monitor Valkey/Redis with Percona Monitoring and Management](https://www.percona.com/blog/how-to-monitor-valkey-redis-with-percona-monitoring-and-management/)**
>
> How to add external exporters to Percona Monitoring and Management (PMM) and monitor various services. Our focus will be on Valkey/Redis, but the principles apply to other technologies as well.

In my docker-compose I added a service with redis\_exporter

```auto
version: '3.7'
services:

  valkey:
    image: valkey/valkey:8
    environment:
      - ALLOW_EMPTY_PASSWORD=yes
    ports:
      - "6379:6379"
    volumes:
      - valkey_data:/data
    healthcheck:
      test: ["CMD", "redis-cli", "ping"]
      interval: 5s
      timeout: 3s
      retries: 5

  redis_exporter:
    platform: "linux/amd64"
    image: oliver006/redis_exporter:v1.29.0
    ports:
      - "9121:9121"
    command: ["-redis.addr=redis://valkey:6379"]
    depends_on:
      - valkey
    environment:
      REDIS_ADDR: redis://valkey:6379

```

Then I went into PMM in the settings under Inventory and added a new service.

I used `redis_exporter` as the URL, the `/metrics` folder and port 9121.

 ![Screenshot 2024-12-17 at 1.00.43 PM](https://us1.discourse-cdn.com/flex019/uploads/percona1/original/3X/8/b/8b3f6fb5c725dca872d4c7802d1ed7cd2fa121ea.png)

For some reason Inventory was showing Fail, but I saw the metrics in PMM metrics Explorer.

I also downloaded the dashboard in the Grafana gallery and imported it into PMM.

> **[Redis Dashboard for Prometheus Redis Exporter 1.x | Grafana Labs](https://grafana.com/grafana/dashboards/763-redis-dashboard-for-prometheus-redis-exporter-1-x/)**

I opened the dashboard and saw that everything was working as it should, made a few queries to see the metrics change.

 ![Screenshot 2024-12-17 at 12.56.14 PM](https://us1.discourse-cdn.com/flex019/uploads/percona1/original/3X/c/5/c53ed6c945d572278d1d75de144477f03ec266d6.png)
