Redis monitoring with Netdata

What is Redis?

Redis is a popular open-source, in-memory data store used across industries by a variety of companies, including Github, Stack Overflow, Twitter and Netdata!

Redis supports multiple use-cases including:

Redis + Netdata

Netdata makes monitoring and troubleshooting Redis simple, effective and powerful.

The prerequisite to this guide is that you have Redis & Netdata installed and running.

Installing Netdata is as easy as it gets; just follow these steps to sign up for a free Netdata account and install the open source agent.

Netdata automatically discovers the Redis service and starts monitoring it, if it is accessible on the localhost on port 6379 (the default port), or via one of the following unix sockets.

image

If your Redis service is configured differently or is password protected, you will need to configure the collector.

You should now see a Redis section on the Overview tab that’s already populated with charts about all the metrics you care about!

Redis demo room

Netdata has a public demo space where you can explore different monitoring use-cases.

Check out the Redis demo room to explore and interact with the charts and metrics described in this guide.

Monitoring Redis metrics with Netdata

High fidelity monitoring of Redis enables you to understand the performance of your Redis datastore, whether it is configured optimally or not and also identify any problems that may arise.

This section of the guide explains what metrics are key to understanding Redis and how to make sense of them. All of these metrics are collected by Netdata.

Connections

Redis accepts clients’ connections on the configured listening TCP port and on the Unix socket, if enabled. Redis is capable of handling many active connections, up to a threshold of maxclients, which describes the maximum number of clients that can connect to Redis. The default value is 10,000 client connections. If your system does not have sufficient file descriptors to comply with the maxclients configuration then Redis will use the number of available file descriptors as the limit.

image

The current state of the clients connected to or attempting to connect to Redis are monitored in a separate chart.

Connected: Client connected to Redis.

Blocked: Client blocked from connecting to Redis.

In the timeout table: Clients in the timeout table due to be disconnected.

Tracking: Clients for which client tracking is enabled

Performance

These metrics are the key indicators of Redis performance and overall system health.

Latency

Processed commands per second

image

Lookup hitrate

Lookup Hitrate = (Keyspace hits / (Keyspace hits + Keyspace misses))

image

Memory

Memory Usage

image

Memory fragmentation

image

Evicted keys

Network

Bytes received and sent

image

Replication

Redis supports failover and high availability with asynchronous replication.

Connected replicas

Time since last interaction

Persistence

Redis writes data to disk (durable storage) for persistence. There are multiple persistence options including RDB (Redis database) persistence performance point in time snapshots at specified intervals, AOF (Append only file) persistence logs every write operation received by the server, that will be played again at server startup, reconstructing the original dataset, a mix of the two approaches and also an option to choose no persistence.

If you are using Redis as a cache then persistence may not be necessary. For further information on Redis persistence refer to the official documentation.

Changes

image

Current BGSAVE time

Status of last RDB BGSAVE

RDB last SAVE time

AOF file size

Commands

Commands by type

image

Total CPU time consumed by commands

image

Avg CPU time consumed per command execution

image

Keyspace

Expired keys

Keys per database

Keys with expiration per database

Uptime

Uptime

Get Netdata

Sign up for free

Want to see a demonstration of Netdata for multiple use cases?

Go to Live Demo