Redis

INFO [section]

The INFO command returns information and statistics about the server in a format that is simple to parse by computers and easy to read by humans.

The optional parameter can be used to select a specific section of information:

It can also take the following values:

When no parameter is provided, the default option is assumed.

Return value

Bulk string reply: as a collection of text lines.

Lines can contain a section name (starting with a # character) or a property. All the properties are in the form of field:value terminated by \r\n.

redis>  INFO
ERR Don't know what to do for "info"
redis> 

Notes

Please note depending on the version of Redis some of the fields have been added or removed. A robust client application should therefore parse the result of this command by skipping unknown properties, and gracefully handle missing fields.

Here is the description of fields for Redis >= 2.4.

Here is the meaning of all fields in the server section:

Here is the meaning of all fields in the clients section:

Here is the meaning of all fields in the memory section:

Ideally, the used_memory_rss value should be only slightly higher than used_memory. When rss >> used, a large difference means there is memory fragmentation (internal or external), which can be evaluated by checking mem_fragmentation_ratio. When used >> rss, it means part of Redis memory has been swapped off by the operating system: expect some significant latencies.

Because Redis does not have control over how its allocations are mapped to memory pages, high used_memory_rss is often the result of a spike in memory usage.

When Redis frees memory, the memory is given back to the allocator, and the allocator may or may not give the memory back to the system. There may be a discrepancy between the used_memory value and memory consumption as reported by the operating system. It may be due to the fact memory has been used and released by Redis, but not given back to the system. The used_memory_peak value is generally useful to check this point.

Here is the meaning of all fields in the persistence section:

changes_since_last_save refers to the number of operations that produced some kind of changes in the dataset since the last time either SAVE or BGSAVE was called.

If AOF is activated, these additional fields will be added:

If a load operation is on-going, these additional fields will be added:

Here is the meaning of all fields in the stats section:

Here is the meaning of all fields in the replication section:

If the instance is a slave, these additional fields are provided:

If a SYNC operation is on-going, these additional fields are provided:

If the link between master and slave is down, an additional field is provided:

The following field is always provided:

For each slave, the following line is added:

Here is the meaning of all fields in the cpu section:

The commandstats section provides statistics based on the command type, including the number of calls, the total CPU time consumed by these commands, and the average CPU consumed per command execution.

For each command type, the following line is added:

The cluster section currently only contains a unique field:

The keyspace section provides statistics on the main dictionary of each database. The statistics are the number of keys, and the number of keys with an expiration.

For each database, the following line is added:

Comments powered by Disqus