Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

redis db #243

Open
jhfb opened this issue Aug 11, 2022 · 2 comments
Open

redis db #243

jhfb opened this issue Aug 11, 2022 · 2 comments

Comments

@jhfb
Copy link

jhfb commented Aug 11, 2022

When testing the redis performance, all the requests are wrong. Do you have any requirements for the redis version? Has anyone tested redis normally?

@dbsid
Copy link
Collaborator

dbsid commented Aug 29, 2022

could you post the error message?

@filipecosta90
Copy link
Contributor

@jhfb glad to assist with further help, have you tried the following?:

BTW, ignore the performance numbers given I'm running this locally.

Build it:

check for ./bin/go-ycsb binary

make

Spin redis ( with modules so we can test JSON as well ):

docker run -p 6379:6379 redis/redis-stack-server:latest

Run it:

HASH variant ( this is the default and will work on any "type" of redis provider ) :

./bin/go-ycsb load redis --interval 1 -p recordcount=100000 -p threadcount=16 -p redis.addr=localhost:6379 -p redis.datatype=hash -p fieldcount=100 -p fieldsize=100

here's a sample output of it:

$ ./bin/go-ycsb load redis --interval 1 -p recordcount=100000 -p threadcount=16 -p redis.addr=localhost:6379 -p redis.datatype=hash -p fieldcount=100 -p fieldsize=100
Using the redis datatype: hash
***************** properties *****************
"fieldsize"="100"
"dotransactions"="false"
"threadcount"="16"
"fieldcount"="100"
"recordcount"="100000"
"redis.addr"="localhost:6379"
"redis.datatype"="hash"
"command"="load"
"measurement.interval"="1"
**********************************************
INSERT - Takes(s): 1.0, Count: 8275, OPS: 8290.1, Avg(us): 1554, Min(us): 281, Max(us): 9039, 99th(us): 4475, 99.9th(us): 8047, 99.99th(us): 9031
INSERT - Takes(s): 2.0, Count: 16606, OPS: 8316.0, Avg(us): 1542, Min(us): 281, Max(us): 9431, 99th(us): 4403, 99.9th(us): 8367, 99.99th(us): 9079
INSERT - Takes(s): 3.0, Count: 24910, OPS: 8312.2, Avg(us): 1549, Min(us): 281, Max(us): 9807, 99th(us): 4387, 99.9th(us): 8415, 99.99th(us): 9615
INSERT - Takes(s): 4.0, Count: 33280, OPS: 8326.6, Avg(us): 1547, Min(us): 281, Max(us): 9839, 99th(us): 4347, 99.9th(us): 8431, 99.99th(us): 9799
INSERT - Takes(s): 5.0, Count: 41540, OPS: 8312.9, Avg(us): 1550, Min(us): 267, Max(us): 9823, 99th(us): 4471, 99.9th(us): 8479, 99.99th(us): 9799
INSERT - Takes(s): 6.0, Count: 49884, OPS: 8318.7, Avg(us): 1548, Min(us): 267, Max(us): 9975, 99th(us): 4559, 99.9th(us): 8567, 99.99th(us): 9823
INSERT - Takes(s): 7.0, Count: 57697, OPS: 8246.2, Avg(us): 1564, Min(us): 267, Max(us): 10359, 99th(us): 4847, 99.9th(us): 8967, 99.99th(us): 10079
INSERT - Takes(s): 8.0, Count: 64517, OPS: 8067.8, Avg(us): 1598, Min(us): 267, Max(us): 10631, 99th(us): 5247, 99.9th(us): 9151, 99.99th(us): 10559
INSERT - Takes(s): 9.0, Count: 71763, OPS: 7976.4, Avg(us): 1617, Min(us): 267, Max(us): 11063, 99th(us): 5343, 99.9th(us): 9559, 99.99th(us): 10743
INSERT - Takes(s): 10.0, Count: 79565, OPS: 7958.7, Avg(us): 1620, Min(us): 267, Max(us): 11127, 99th(us): 5355, 99.9th(us): 9519, 99.99th(us): 10767
INSERT - Takes(s): 11.0, Count: 87068, OPS: 7917.5, Avg(us): 1628, Min(us): 267, Max(us): 11063, 99th(us): 5459, 99.9th(us): 9519, 99.99th(us): 10743
INSERT - Takes(s): 12.0, Count: 94642, OPS: 7889.0, Avg(us): 1633, Min(us): 267, Max(us): 10927, 99th(us): 5459, 99.9th(us): 9479, 99.99th(us): 10647
Run finished, takes 12.722792926s
INSERT - Takes(s): 12.7, Count: 99815, OPS: 7848.1, Avg(us): 1628, Min(us): 242, Max(us): 11111, 99th(us): 5479, 99.9th(us): 9575, 99.99th(us): 10791

confirmation we indeed have commandstats without errors:
notice that there are no failed_calls:

$ redis-cli info commandstats
# Commandstats
cmdstat_info:calls=2,usec=36,usec_per_call=18.00,rejected_calls=0,failed_calls=0
cmdstat_hset:calls=100000,usec=5389248,usec_per_call=53.89,rejected_calls=0,failed_calls=0
cmdstat_hello:calls=10,usec=49,usec_per_call=4.90,rejected_calls=0,failed_calls=0

JSON variant:

./bin/go-ycsb load redis --interval 1 -p recordcount=1000000 -p threadcount=16 -p redis.addr=localhost:6379 -p redis.datatype=json -p fieldcount=100 -p fieldsize=100

here's a sample output of it:

$ ./bin/go-ycsb load redis --interval 1 -p recordcount=100000 -p threadcount=16 -p redis.addr=localhost:6379 -p redis.datatype=json -p fieldcount=100 -p fieldsize=100
Using the redis datatype: json
***************** properties *****************
"measurement.interval"="1"
"redis.addr"="localhost:6379"
"dotransactions"="false"
"command"="load"
"redis.datatype"="json"
"recordcount"="100000"
"fieldcount"="100"
"fieldsize"="100"
"threadcount"="16"
**********************************************
INSERT - Takes(s): 1.0, Count: 5753, OPS: 5786.3, Avg(us): 2356, Min(us): 374, Max(us): 18719, 99th(us): 12679, 99.9th(us): 17151, 99.99th(us): 17727
INSERT - Takes(s): 2.0, Count: 10969, OPS: 5499.8, Avg(us): 2442, Min(us): 374, Max(us): 29647, 99th(us): 15799, 99.9th(us): 26431, 99.99th(us): 29023
INSERT - Takes(s): 3.0, Count: 17825, OPS: 5952.7, Avg(us): 2241, Min(us): 374, Max(us): 24575, 99th(us): 10519, 99.9th(us): 19999, 99.99th(us): 23007
INSERT - Takes(s): 4.0, Count: 20907, OPS: 5234.4, Avg(us): 2484, Min(us): 340, Max(us): 39007, 99th(us): 19599, 99.9th(us): 37087, 99.99th(us): 38911
INSERT - Takes(s): 5.0, Count: 27868, OPS: 5580.1, Avg(us): 2317, Min(us): 340, Max(us): 35551, 99th(us): 15375, 99.9th(us): 30351, 99.99th(us): 35359
INSERT - Takes(s): 6.0, Count: 34580, OPS: 5768.9, Avg(us): 2242, Min(us): 327, Max(us): 30191, 99th(us): 10391, 99.9th(us): 24735, 99.99th(us): 29919
INSERT - Takes(s): 7.0, Count: 36513, OPS: 5220.0, Avg(us): 2388, Min(us): 327, Max(us): 39199, 99th(us): 17727, 99.9th(us): 37855, 99.99th(us): 39071
INSERT - Takes(s): 8.0, Count: 40126, OPS: 5019.4, Avg(us): 2464, Min(us): 327, Max(us): 43967, 99th(us): 19631, 99.9th(us): 39935, 99.99th(us): 42591
INSERT - Takes(s): 9.0, Count: 46885, OPS: 5212.6, Avg(us): 2389, Min(us): 327, Max(us): 40831, 99th(us): 16511, 99.9th(us): 39167, 99.99th(us): 40671
INSERT - Takes(s): 10.0, Count: 52073, OPS: 5210.2, Avg(us): 2391, Min(us): 327, Max(us): 39263, 99th(us): 10815, 99.9th(us): 38527, 99.99th(us): 39135
INSERT - Takes(s): 11.0, Count: 56440, OPS: 5133.3, Avg(us): 2427, Min(us): 327, Max(us): 38591, 99th(us): 9767, 99.9th(us): 37055, 99.99th(us): 38559
INSERT - Takes(s): 12.0, Count: 61353, OPS: 5115.3, Avg(us): 2439, Min(us): 327, Max(us): 37727, 99th(us): 8839, 99.9th(us): 35711, 99.99th(us): 37567
INSERT - Takes(s): 13.0, Count: 67552, OPS: 5198.6, Avg(us): 2408, Min(us): 327, Max(us): 36383, 99th(us): 8051, 99.9th(us): 32799, 99.99th(us): 36223
INSERT - Takes(s): 14.0, Count: 71836, OPS: 5132.7, Avg(us): 2441, Min(us): 327, Max(us): 35039, 99th(us): 7803, 99.9th(us): 25167, 99.99th(us): 34239
INSERT - Takes(s): 15.0, Count: 72833, OPS: 4857.4, Avg(us): 2500, Min(us): 327, Max(us): 37727, 99th(us): 8471, 99.9th(us): 35423, 99.99th(us): 37599
INSERT - Takes(s): 16.0, Count: 72998, OPS: 4563.8, Avg(us): 2562, Min(us): 327, Max(us): 40767, 99th(us): 9575, 99.9th(us): 38719, 99.99th(us): 40479
INSERT - Takes(s): 17.0, Count: 73810, OPS: 4343.2, Avg(us): 2669, Min(us): 327, Max(us): 73727, 99th(us): 10839, 99.9th(us): 51039, 99.99th(us): 73343
INSERT - Takes(s): 18.0, Count: 79198, OPS: 4401.1, Avg(us): 2644, Min(us): 327, Max(us): 72703, 99th(us): 10079, 99.9th(us): 44671, 99.99th(us): 67135
INSERT - Takes(s): 19.0, Count: 84439, OPS: 4444.9, Avg(us): 2620, Min(us): 327, Max(us): 57887, 99th(us): 9439, 99.9th(us): 39935, 99.99th(us): 51551
INSERT - Takes(s): 20.0, Count: 89220, OPS: 4462.1, Avg(us): 2616, Min(us): 327, Max(us): 47391, 99th(us): 9047, 99.9th(us): 38911, 99.99th(us): 43903
INSERT - Takes(s): 21.0, Count: 92349, OPS: 4398.6, Avg(us): 2653, Min(us): 327, Max(us): 39615, 99th(us): 9143, 99.9th(us): 37855, 99.99th(us): 39487
INSERT - Takes(s): 22.0, Count: 95617, OPS: 4347.4, Avg(us): 2696, Min(us): 327, Max(us): 38815, 99th(us): 9191, 99.9th(us): 36383, 99.99th(us): 38719
INSERT - Takes(s): 23.0, Count: 98876, OPS: 4299.9, Avg(us): 2731, Min(us): 327, Max(us): 38111, 99th(us): 9175, 99.9th(us): 34399, 99.99th(us): 37887
Run finished, takes 23.126728733s
INSERT - Takes(s): 23.1, Count: 99267, OPS: 4293.4, Avg(us): 2728, Min(us): 327, Max(us): 37983, 99th(us): 9127, 99.9th(us): 33727, 99.99th(us): 37663

confirmation that there are no failed calls:

$ redis-cli info commandstats
# Commandstats
cmdstat_hello:calls=10,usec=48,usec_per_call=4.80,rejected_calls=0,failed_calls=0
cmdstat_json.set:calls=100000,usec=19171819,usec_per_call=191.72,rejected_calls=0,failed_calls=0
cmdstat_info:calls=2,usec=39,usec_per_call=19.50,rejected_calls=0,failed_calls=0

Follow up

If the problem persists feel free to reach out either here or via email to performance<at>redis.com

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants