Fortinet black logo

User Guide

Redis monitoring

24.2.0
Copy Link
Copy Doc ID af1daa65-c273-11ec-9fd1-fa163e15d75b:121895
Download PDF

Redis monitoring

This article describes all the available Redis metrics that you can monitor and alert on in FortiMonitor. For certain metrics, it is important to set up alerts when thresholds are breached. In the following sections, key Redis metrics are described in detail. Configure monitoring and/or alerting thresholds based on your application requirements.

For a list of all available metrics, see Redis.

Redis application metrics

Monitoring and setting up alerts for Redis-specific metrics can help you identify and investigate potential problems on the Redis application itself. The metrics described in the following sections gather data to help you plan for future infrastructure upgrades or troubleshoot issues related to availability and performance.

Availability metrics

The following metrics validate that your Redis instance can be reached by clients.

Metric

Description

Monitor

Alert

Connected clients

The number of clients connected to your Redis application node.

Once Redis reaches its configured maxclients, it stops accepting new connections and produces an error.


Uptime in seconds

The number of seconds since the Redis instance was started.

Use this metric to ensure that the Redis instance is not restarting frequently.


Connected slaves

The number of slaves connected to the master.

Latency may occur if the slave is unable to connect to the master. Also, changes to the number of connected slaves may indicate issues with the master or the slave instances.


Replication: role (master=1, slave=0)

The role of the Redis instance in terms of replication.


Query performance metrics

The following metrics measure the performance of your Redis instance. Metrics that track used memory, expired and evicted keys, and blocked clients can be added to the instance.

Metric

Description

Monitor

Alert

Used memory

The amount of memory in bytes allocated by the Redis instance.

If the used memory exceeds the system memory of your Redis instance, the system will start swapping causing performance issues.


Used memory peak

The peak memory used by the Redis instance.



Used memory rss

The amount of memory in bytes allocated by the Redis instance as seen by the OS.



Expired keys

Redis supports the time-to-live (TTL) property for each key. The key is deleted once the TTL expires. Expired keys can pile up in the memory unless evicted.



Evicted keys

The number of keys removed when the maxmemory limit is reached. Evicting a large number of keys may cause latency.


Blocked clients

The number of clients currently blocked while waiting on a blocking request.


Keyspace hits

The number of successful key lookups in the main dictionary.

A low hits-to-misses ratio means that clients are looking for keys that have expired or evicted



Keyspace misses

The number of failed key lookups in the main dictionary

A low hits-to-misses ratio means that clients are looking for keys that have expired or evicted



Persistence: background save in progress

The number of background save processes.

These processes causes degraded performance. You can use this metric to diagnose whether performance issues are caused by background save processes.


Other metrics

Other metrics such as length of lists, total commands processed, and more are described in the following table.

Metric

Description

Monitor

Alert

Length of list

The number of entries in a Redis list.



Changes since last save

The number of changes to the Redis database since the last dump. This is the data that will be lost when the Redis instance restarts.



Pub/sub channels

The total number of channels used for pub/sub.



Pub/sub patterns

The number of pub/sub patterns.

Total commands processed

The total number of commands processed by the Redis. The value is incremented every time Redis completes a command from connected clients.

Since commands in Redis are processed sequentially, a high number of commands may cause latency. This metric is one of the things you can look at to diagnose latency issues.

Redis monitoring

This article describes all the available Redis metrics that you can monitor and alert on in FortiMonitor. For certain metrics, it is important to set up alerts when thresholds are breached. In the following sections, key Redis metrics are described in detail. Configure monitoring and/or alerting thresholds based on your application requirements.

For a list of all available metrics, see Redis.

Redis application metrics

Monitoring and setting up alerts for Redis-specific metrics can help you identify and investigate potential problems on the Redis application itself. The metrics described in the following sections gather data to help you plan for future infrastructure upgrades or troubleshoot issues related to availability and performance.

Availability metrics

The following metrics validate that your Redis instance can be reached by clients.

Metric

Description

Monitor

Alert

Connected clients

The number of clients connected to your Redis application node.

Once Redis reaches its configured maxclients, it stops accepting new connections and produces an error.


Uptime in seconds

The number of seconds since the Redis instance was started.

Use this metric to ensure that the Redis instance is not restarting frequently.


Connected slaves

The number of slaves connected to the master.

Latency may occur if the slave is unable to connect to the master. Also, changes to the number of connected slaves may indicate issues with the master or the slave instances.


Replication: role (master=1, slave=0)

The role of the Redis instance in terms of replication.


Query performance metrics

The following metrics measure the performance of your Redis instance. Metrics that track used memory, expired and evicted keys, and blocked clients can be added to the instance.

Metric

Description

Monitor

Alert

Used memory

The amount of memory in bytes allocated by the Redis instance.

If the used memory exceeds the system memory of your Redis instance, the system will start swapping causing performance issues.


Used memory peak

The peak memory used by the Redis instance.



Used memory rss

The amount of memory in bytes allocated by the Redis instance as seen by the OS.



Expired keys

Redis supports the time-to-live (TTL) property for each key. The key is deleted once the TTL expires. Expired keys can pile up in the memory unless evicted.



Evicted keys

The number of keys removed when the maxmemory limit is reached. Evicting a large number of keys may cause latency.


Blocked clients

The number of clients currently blocked while waiting on a blocking request.


Keyspace hits

The number of successful key lookups in the main dictionary.

A low hits-to-misses ratio means that clients are looking for keys that have expired or evicted



Keyspace misses

The number of failed key lookups in the main dictionary

A low hits-to-misses ratio means that clients are looking for keys that have expired or evicted



Persistence: background save in progress

The number of background save processes.

These processes causes degraded performance. You can use this metric to diagnose whether performance issues are caused by background save processes.


Other metrics

Other metrics such as length of lists, total commands processed, and more are described in the following table.

Metric

Description

Monitor

Alert

Length of list

The number of entries in a Redis list.



Changes since last save

The number of changes to the Redis database since the last dump. This is the data that will be lost when the Redis instance restarts.



Pub/sub channels

The total number of channels used for pub/sub.



Pub/sub patterns

The number of pub/sub patterns.

Total commands processed

The total number of commands processed by the Redis. The value is incremented every time Redis completes a command from connected clients.

Since commands in Redis are processed sequentially, a high number of commands may cause latency. This metric is one of the things you can look at to diagnose latency issues.