You can run the redis-benchmark command to test the performance of ApsaraDB for Redis.
The following command is for your reference:
Usage: redis-benchmark [-h] [-p] [-c] [-n[-k]
-h Server hostname (default 127.0.0.1)
-p Server port (default 6379)
-s Server socket (overrides host and port)
-c Number of parallel connections (default 50)
-n Total number of requests (default 10000)
-d Data size of SET/GET value in bytes (default 2)
-k 1=keep alive 0=reconnect (default 1)
-r Use random keys for SET/GET/INCR, random values for SADD
Using this option, the benchmark will get/set keys
in the form mykey_rand:000000012456 instead of constant
keys. The argument determines the max
number of values for the random number. For instance
if set to 10 only rand:000000000000 - rand:000000000009
range will be allowed.
-P Pipelinerequests. Default 1 (no pipeline).
-q Quiet. Show query/sec values: only displays the number of requests processed per second
-csv Output in CSV format
-l Loop. Run the tests continuously: permanent testing
-t Only run the list of tests that are separated by a comma. The test
names are the same as those produced as the output.
-I Idle mode. Only open N idle connections.