云内存Redis压力测试

摘要:测试脚本测试结果测试结果读写比例快杰快杰快杰快杰快杰

压力测试

本篇目录

物理机普通机型测试快杰主备redis产品测试

物理机普通机型测试

测试条件

1.开启pipeline,不同连接数.

2.关闭pipeline,不同连接数

3.开启pipeline,不同Data size

测试脚本模板:

#!/bin/bash
for clients in {1,2,4,8,16,32,64,128,256,512,800}; do
echo $clients
redis-benchmark  -c $clients -n 5000000 -P 100 -h 10.10.214.139  -d 256 -t get,set -q
done

测试结果:

华北一可用区B

1.开启pipeline,不同连接数

redis-benchmark  -c $连接数 -n 5000000 -P 100 -h IP  -d 256 -t get,set

image

2.关闭pipeline,不同连接数

redis-benchmark  -c $连接数 -n 1000000 -h IP -d 256 -t get,set -q

image

3.开启pipeline,不同Data size

redis-benchmark -c 64 -n 5000000 -P 100 -h IP -d $字节 -t get,set -q

image

快杰主备redis产品测试

测试环境redis-server

软件版本:6.0

服务器机型:快杰版主备redis、物理机普通机型

产品规格:快杰1G、快杰2G、快杰4G、快杰6G、快杰8G、物理机普通机型

redis-benchmark

服务器机型: 快杰O型

系统版本:CentOS 8.3

机器配置:16C/16G

memtier_benchmark

服务器机型: 快杰O型

系统版本:CentOS 6.4

机器配置:16C/16G

测试场景1. 不同连接数,关闭pipeline

测试脚本:

#!/bin/bash
for clients in {1,2,4,8,16,32,64,128,256,512,800}; do
    redis-benchmark  -c $连接数 -n 1000000 -h IP -d 256 -t get,set -q --threads 4
done

测试结果

Set性能

连接数1248163264128256512800

快杰1G14118269915057183222117619137741153822166417147819153609153421快杰2G14067275505198685077105241142653163671142633142612153468159565快杰4G13921281365122184997117495142673159769159769159846159616153421快杰6G13921277734871185091114116142653166334166417166361153444153444快杰8G14068279395056886850117495142633159744159718159872159769147819物理机普通机型897916774280364072252919599176426366813686946910172364

Get性能

连接数1248163264128256512800

快杰1G165093097258750102438153657181587210482199720199680190258199521快杰2G15667289515796096880142673173671189720188680180817181827192216快杰4G16509307335769097880142673181620199760190367190403189760192897快杰6G16578307095782298427142653173671190216199680195114191587212024快杰8G165783081559633102553142836190222210260190186199920210128209995物理机普通机型997319272315714780366246861459037190973935319589291907
折线图

Set QPS
image
Get QPS
image

2. 不同data size,关闭pipeline

测试脚本:

#!/bin/bash
for data_size in {1,8,64,512,4096}; do
    redis-benchmark -c 64 -n 1000000 -h IP -d $data_size -t get,set -q --threads 4
done
# 32KiB大小的data size长时间跑容易使1GB容量规格实例oom。
data_size=32768
redis-benchmark -c 64 -n 50000 -P 100 -h IP -d $data_size -t get,set -q --threads 4

测试结果

Set性能

字节1字节8字节64字节512字节4096字节32768字节

快杰1G1736711738521664441289986662213078快杰2G1815211736711597691377416544913077快杰4G1817521815871736711428166141312659快杰6G1664171597951664721479286892213075快杰8G1815541636091526941436576661312676

Get性能

字节1字节8字节64字节512字节4096字节32768字节

快杰1G19968019018619043919022211746761425快杰2G19972019996019972019018611760557028快杰4G21026019996021021619996012103653319快杰6G19941519022219992019968011760561519快杰8G19992018155418155418155411748157110
折线图

Set QPS
image
Get QPS
image

3. 不同连接数,开启pipeline

测试脚本:

#!/bin/bash
for clients in {1,2,4,8,16,32,64,128,256,512,800}; do
    redis-benchmark  -c $clients -n 5000000 -P 100 -h IP  -d 256 -t get,set -q --threads 4
done

测试结果

Set性能

连接数1248163264128256512800

快杰1G332933487044486854524989525430525265511561498305463907433162406471快杰2G350434475465511823539257525430511770498454511142453391424052442712快杰4G356709475330539548539374524824511718524989511195464037443262414593快杰6G344400475556512242525154525320538851498902511195498256423980415006快杰8G350459487187540073539374539723554262538793511665463520433200398883物理机普通机型137155165579182681178424189343184836195266207331202609193318190614

Get性能

连接数1248163264128256512800

快杰1G6657781174536153704216627861537042166389315328011533742142409515323321421666快杰2G6443291109631153562616633401663893166223415342121661681153468314232841328021快杰4G6457781174812153711116067821663893166168116622341662234166278615332721532332快杰6G6458671051082166334016650011665001171159416611291660577166112915328011531393快杰8G6442461174536166555616633401663340166168115337421533742153562615337421423284物理机普通机型230075406834418795475737491980498952505152542711501705501403482020
折线图

Set QPS
image
Get QPS
image

4. 短链接压测

短链接的压测主要是测试在不同读写比例情况下不同规格redis产品的性能。
测试脚本:

#!/bin/bash
memtier_benchmark -s IP -p 6379 -c 30 -t 8 -n 1000 --ratio=10:0 --reconnect-interval=1
memtier_benchmark -s IP -p 6379 -c 30 -t 8 -n 1000 --ratio=5:5 --reconnect-interval=1
memtier_benchmark -s IP -p 6379 -c 30 -t 8 -n 1000 --ratio=0:10 --reconnect-interval=1

测试结果
读写比例10:05:50:10

快杰1G291112803928433快杰2G277482813627952快杰4G282692819027664快杰6G274912787028297快杰8G280372796527916

原创文章,作者:网友投稿,如若转载,请注明出处:https://www.cloudads.cn/archives/4463.html

发表评论

登录后才能评论