4

I wan to know that how to check the performance of Redis server and what could be bottleneck. I have run redis-cli -h 127.0.0.1 -p 6379 --stat command and get following stats.

enter image description here

if some can suggest what needs to be done and what other mtrics need to be checked.

Amritpal Singh
  • 1,765
  • 1
  • 13
  • 20

4 Answers4

3

Redis includes the redis-benchmark utility that simulates running commands done by N clients at the same time

Usage: redis-benchmark [-h <host>] [-p <port>] [-c <clients>] [-n <requests]> [-k <boolean>]

MONITOR is a debugging command that streams back every command processed by the Redis server. It can help in understanding what is happening to the database. This command can both be used via redis-cli and via telnet.

$ redis-cli monitor

If you are experiencing latency problems, probably you know how to measure it in the context of your application, or maybe your latency problem is very evident even macroscopically. However redis-cli can be used to measure the latency of a Redis server in milliseconds, just try:

redis-cli --latency -h `host` -p `port`

Hope you can get some help from here. Reference Link: http://redis.io/topics/benchmarks

Aman Garg
  • 3,122
  • 4
  • 24
  • 32
0

Have you seen this redis topic about benchmark?

The redis-benchmark program is a quick and useful way to get some figures and evaluate the performance of a Redis instance on a given hardware. However, by default, it does not represent the maximum throughput a Redis instance can sustain.

hex7c0
  • 61
  • 1
  • 5
0

To identify performance bottlenecks, invoke slowlog get in Redis-cli. It will return the list of commands whose execution time exceeded a duration defined in redis.conf. This duration concerns only the processing of the requests, it does not include the communication time. The default value is one second, which is a lot for Redis.

Redis.conf includes two values related to slow logs:

  • slowlog-log-slower-than defines the minimum execution time, inn microseconds, of the request to be logged;
  • slowlog-max-len defines the maxum number of entries to be stored in the slow log.

As usual with Redis, you can use config set to modify these setting without restarting the server. just don't forget these logs are stored in memory.

You can clear the slow log entries using slowlog reset.

Pascal Le Merrer
  • 5,883
  • 20
  • 35
0

you can also user Redis Stat, great tool for realtime checking.

Regards,

bubulemaster
  • 221
  • 2
  • 8