docker—服务器与本地系统的redis性能差异

xmd2e60i  于 2021-06-09  发布在  Redis
关注(0)|答案(0)|浏览(256)

我在我的服务器上进行了压力测试,每秒1000个请求的延迟时间是1秒,我发现延迟问题是因为redis,所以我在centos 7上(centos在vmware虚拟机上cpu:22核,ram:30GB)通过

redis-benchmark -q -n 100000

请给出以下结果:

PING_INLINE: 26420.08 requests per second
PING_BULK: 27389.76 requests per second
SET: 27144.41 requests per second
GET: 26702.27 requests per second
INCR: 27041.64 requests per second
LPUSH: 27203.48 requests per second
RPUSH: 27188.69 requests per second
LPOP: 27005.13 requests per second
RPOP: 27367.27 requests per second
SADD: 26645.35 requests per second
HSET: 26881.72 requests per second
SPOP: 27624.31 requests per second
LPUSH (needed to benchmark LRANGE): 27100.27 requests per second
LRANGE_100 (first 100 elements): 20703.93 requests per second
LRANGE_300 (first 300 elements): 11763.32 requests per second
LRANGE_500 (first 450 elements): 9627.42 requests per second
LRANGE_600 (first 600 elements): 8078.20 requests per second
MSET (10 keys): 26709.40 requests per second

但是当我在我的笔记本电脑ubuntu19.04(cpu:corei3,ram:12gb)上检查dockerized redis的性能时

redis-benchmark -q -n 100000

请给出以下结果:

PING_INLINE: 117096.02 requests per second
PING_BULK: 126742.72 requests per second
SET: 119904.08 requests per second
GET: 126903.55 requests per second
INCR: 127064.80 requests per second
LPUSH: 111482.72 requests per second
RPUSH: 121359.23 requests per second
LPOP: 112994.35 requests per second
RPOP: 123152.71 requests per second
SADD: 130378.09 requests per second
HSET: 130039.02 requests per second
SPOP: 103199.18 requests per second
LPUSH (needed to benchmark LRANGE): 88809.95 requests per second
LRANGE_100 (first 100 elements): 51046.45 requests per second
LRANGE_300 (first 300 elements): 17853.96 requests per second
LRANGE_500 (first 450 elements): 12784.45 requests per second
LRANGE_600 (first 600 elements): 9744.69 requests per second
MSET (10 keys): 132802.12 requests per second

为什么我的本地系统的性能要比服务器好得多,尽管服务器的硬件能力更高?

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题