redis 性能问题排查

来源:互联网 发布:javascript classname 编辑:程序博客网 时间:2024/05/16 00:25

Here is a non exhaustive list of potential reasons:

  • Inadequate hardware (network, memory, CPU)
  • Software based virtualization (Xen on low-end hardware for instance)
  • Not enough memory, generating swapping at the OS level
  • Too many O(n) operations (like KEYS) executed in the single-threaded engine
  • Large objects stored in Redis, leading to uncontrolled expansion of the communication buffers
  • Huge number of simultaneous sessions (>30000)
  • Too many connection operations per second (Redis is not a webserver, connections are supposed to be permanent, not transient).
  • Too many roundtrips generated by the client application (no pipelining or aggregated command usage)
  • Large fork operations generated by bgsave or AOF rewrite (especially on VMs)
  • I/O related latencies when AOF is used
  • Accumulation of many expire operations triggered at the same time
  • Accumulation of memory in client and master/slave communication buffers, or slow log data
  • TCP incast conditions when network bandwidth consumption is significant
  • Using distributed storage (and especially cloudy ones such as EC2 EBS) to store dump or AOF files

There are probably many other reasons, related to the workload generated by your own application.

If some people think about other general reasons, we can add them to this list.

0 0
原创粉丝点击