Monitoring Redis

This guide helps you configure Monitoring to monitor Redis.

Redis is an open source advanced key-value store. It is often referred to as adata structure server since values can contain strings, hashes, lists, sets andsorted sets. For more information, visitredis.io.

This functionality is only available for agents running on Linux. It isnot available on Windows.

Note: You can now collect metrics from your Redis instance using theOps Agent, the primary andpreferred agent for collecting telemetry from your Compute Engine instances.For details, seeconfiguring the Ops Agent forRedis.

Discovery

Monitoring discovers Redis services running in your Cloud Platformproject if you have the following:

  • VM instances withredis in their names.
  • Firewall rules that open port6379.

To see the metrics for Redis, do the following:

  1. In the Google Cloud console, go to the Dashboards page:

    Go toDashboards

    If you use the search bar to find this page, then select the result whose subheading isMonitoring.

  2. Select theRedis dashboard from the list.

Configuring Redis monitoring

The Monitoring agent uses thehiredis client library to monitor Redis. After installing Redis, installhiredis by running thefollowing commands:

  • RHEL and CentOS

        sudo yum install epel-release    sudo yum install hiredis
  • Ubuntu 18.04 LTS, 16.04 LTS, and Debian 9

        sudo apt-get install libhiredis0.13
  • SLES

        sudo zypper install libhiredis0_13

Configuring Monitoring

To monitor Redis, perform the following actions on your VM instance afterinstalling the monitoring agent:

  1. Install the Redis configuration file,redis.conf,by running the following command:

    (cd /etc/stackdriver/collectd.d/ && sudo curl -O https://raw.githubusercontent.com/Stackdriver/stackdriver-agent-service-configs/master/etc/collectd.d/redis.conf)
  2. If your Redis instance is password-protected, or if you are using anonstandard host or port for Redis, asroot, editredis.conf byfollowing the instructions at the top of the file.

  3. Restart the monitoring agent by running the following command:

    sudo service stackdriver-agent restart

For more information on thecollectdredis plugin, seePlugin:Redis.

Redis metrics

The full list of metrics the Redis plugin monitors is atAgent metrics: redis.The actual metrics collected, and the metrics available in theMonitoring menus, can vary.

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2026-02-19 UTC.