Ceph ships with an inbuilt benchmarking tool known as the RADOS bench, which can be used to measure the performance of a Ceph cluster at the pool level. The Rados bench tool supports write, sequential read, and random read benchmarking tests, and it also allows the cleaning of temporary benchmarking data, which is quite neat.
Let's try to run some tests using the rados
bench:
rbd
without cleanup, use the following command:# rados bench -p rbd 10 write --no-cleanup
We get the following screenshot after executing the command:
rbd
pool, run the following:# rados bench -p rbd 10 seq
It might be interesting to know, in this case, why the read test finished in a few seconds, or why it didn't execute for the specified 10 seconds. It's because the read speed is faster than the write speed, and rados bench
had finished reading all the data generated during the write test. However, this behavior depends highly on your HW and SW infrastructure.
rados
bench, execute the following:# rados bench -p rbd 10 rand
The syntax for the rados bench
is as follows:
# rados bench -p <pool_name> <seconds> <write|seq|rand> -b <block size> -t --no-cleanup
-p
or --pool
: Specify the pool name<seconds>
: Test the time in seconds<write|seq|rand>
: The type of test, for example, write, sequential read, or random read-b
: For the block size; by default, it's 4M-t
: The number of concurrent threads; the default is 16--no-cleanup
: The temporary data that is written to the pool by the RADOS bench should not be cleaned. This data will be used for read operations when they are used with sequential reads or random reads. The default is cleaned up.The Rados bench is a pretty handy tool to quickly measure the raw performance of your Ceph cluster, and you can creatively design your test cases based on write, read, and random read profiles.
18.225.254.192