The LSM2 module manages disks, extents, and related metadata, which are stored in the LSM2 DB. LSM2 persists replica I/Os sent by access. In LSM2, SSDs are typically used as cache and Journal disks, while HDDs are used as data disks. In all-flash configurations, data disks are fully SSD-based with no cache disks. A single write request requires updating metadata and writing data to the Journal disk (in some cases, data is not written to the Journal), and then writing to either the cache or data disk. In other words, a single I/O request may involve the LSM2 DB, journal partitions, cache partitions, and data partitions.
The following commands retrieve and display overall LSM2 data as well as performance metrics of the LSM2 DB, journal partitions, cache partitions, and data partitions.
Procedure
Run the following command to view the overall performance information about the LSM module:
zbs-perf-tools chunk lsm summary [--chunk-addr <ip>]
| Parameter | Description |
|---|---|
--chunk-addr <ip> | The zbs-chunkd RPC server address. Default: 127.0.0.1:10200, the chunk on the node where the command is run. |
Output example
$zbs-perf-tools chunk lsm summary
--------------------------------------
instance_id 1
read_iops 0.00
read_bw 0.00 B/s(0.00 B/s)
read_latency 0.00 NS
read_cache_hit 1.00
write_iops 239.00
write_bw 2.67 MB/s(2.55 MiB/s)
write_latency 143.72 US
write_cache_hit 1.00
total_iops 239.00
total_bw 2.67 MB/s(2.55 MiB/s)
total_latency 143.72 US
total_cache_hit 1.00
failed_io_ratio 0.00
hard_io_ratio 0.00
slow_io_ratio 0.00
throttle_latency 0.00 NS
cache_promotion_rate 0.00
cache_promotion_bw 0.00 B/s(0.00 B/s)
cache_writeback_rate 0.00
cache_writeback_bw 0.00 B/s(0.00 B/s)
journal_reclaim_rate 1.00
journal_reclaim_latency 8.74 MS
--------------------------------------Output note
| Parameter | Description |
|---|---|
total_iops | The total IOPS of the LSM module in the last 1 second. |
total_bw | The total bandwidth of the LSM module in the last 1 second. |
total_latency | The average total latency of the LSM module in the last 1 second. |
total_cache_hit | The total cache hit rate of the LSM module in the last 1 second. |
read_iops | The read IOPS of the LSM module in the last 1 second. |
read_bw | The read bandwidth of the LSM module in the last 1 second. |
read_latency | The average read latency of the LSM module in the last 1 second. |
read_cache_hit | The read cache hit rate of the LSM module in the last 1 second. |
write_iops | The write IOPS of the LSM module in the last 1 second. |
write_bw | The write bandwidth of the LSM module in the last 1 second. |
write_latency | The average write latency of the LSM module in the last 1 second. |
write_cache_hit | The write cache hit rate of the LSM module in the last 1 second. |
failed_io_ratio | The failed I/O ratio of the LSM module in the last 1 second. |
hard_io_ratio | The hard I/O ratio of the LSM module in the last 1 second. |
slow_io_ratio | The slow I/O ratio of the LSM module in the last 1 second. |
throttle_latency | The throttle latency of the LSM module in processing I/O in the last 1 second. |
cache_promotion_rate | The IOPS written from data partitions to cache partitions by LSM in the last 1 second. |
cache_promotion_bw | The bandwidth written from data partitions to cache partitions by LSM in the last 1 second. |
cache_writeback_rate | The IOPS written back from cache partitions to data partitions by LSM in the last 1 second. |
cache_writeback_bw | The bandwidth written back from cache partitions to data partitions by LSM in the last 1 second. |
journal_reclaim_rate | The reclaim rate of the LSM journal partition in the last 1 second. |
journal_reclaim_latency | The reclaim latency of the LSM journal partition in the last 1 second. |
Information:
In a multi–physical disk pool environment, performance metrics are displayed for each chunk individually. To view the overall performance data, run
zbs-perf-tools node lsm summary.
Procedure
Run the following command to view the performance information about the LSM DB:
zbs-perf-tools chunk lsm db [--chunk-addr <ip>]
| Parameter | Description |
|---|---|
--chunk-addr <ip> | The zbs-chunkd RPC server address. Default: 127.0.0.1:10200, the chunk on the node where the command is run. |
Output example
$zbs-perf-tools chunk lsm db
--------------------------------------
OP RATE LATENCY MAX LATENCY
--------------------------------------
GET 0.00 0.00 NS 0.00 NS
PUT 0.00 0.00 NS 0.00 NS
DELETE 0.00 0.00 NS 113.39 US
WRITE 1.00 2.68 MS 3.19 MS
--------------------------------------Output note
| Parameter | Description |
|---|---|
OP | The LSM DB operation. |
RATE | The number of DB operations in the last 1 second. |
LATENCY | The average latency of DB operations in the last 1 second. |
MAX LATENCY | The maximum latency of DB operations in the last 30 seconds. |
Procedure
Run the following command to view the performance information about the LSM journal partition:
zbs-perf-tools chunk lsm journal [--chunk-addr <ip>]
| Parameter | Description |
|---|---|
--chunk-addr <ip> | The zbs-chunkd RPC server address. Default: 127.0.0.1:10200, the chunk on the node where the command is run. |
Output example
$zbs-perf-tools chunk lsm journal
path /dev/sdf3
commit_rate 0.00
commit_bw 0.00 B/s(0.00 B/s)
commit_latency 0.00 NS
max_commit_latency 0.00 NSOutput note
| Parameter | Description |
|---|---|
PATH | The journal partition. |
COMMIT RATE | The number of commits in the last 1 second. |
COMMIT BW | The commit bandwidth in the last 1 second. |
COMMIT LATENCY | The average commit latency in the last 1 second. |
MAX COMMIT LATENCY | The maximum commit latency in the last 30 seconds. |
Procedure
Run the following command to view the performance information about the LSM cache partition:
zbs-perf-tools chunk lsm cache [--chunk-addr <ip>]
| Parameter | Description |
|---|---|
--chunk-addr <ip> | The zbs-chunkd RPC server address. Default: 127.0.0.1:10200, the chunk on the node where the command is run. |
Output example
$zbs-perf-tools chunk lsm cache
path /dev/sdf4
r/s 0.00
read_bw 0.00 B/s(0.00 B/s)
read_lat 0.00 NS
read_max_lat 0.00 NS
w/s 0.00
write_bw 0.00 B/s(0.00 B/s)
write_lat 0.00 NS
write_max_lat 0.00 NS
sync/s 0.00
sync_lat 0.00 NS
sync_max_lat 0.00 NSOutput note
| Parameter | Description |
|---|---|
PATH | The cache partition. |
R/S | The read IOPS in the last 1 second. |
READ BW | The read I/O bandwidth in the last 1 second. |
READ LAT | The average read I/O latency in the last 1 second. |
READ MAX LAT | The maximum read I/O latency in the last 30 seconds. |
W/S | The write IOPS in the last 1 second. |
WRITE BW | The write I/O bandwidth in the last 1 second. |
WRITE LAT | The average write I/O latency in the last 1 second. |
WRITE MAX LAT | The maximum write I/O latency in the last 30 seconds. |
SYNC/S | The number of syncs in the last 1 second. |
SYNC LAT | The average sync latency in the last 1 second. |
SYNC MAX LAT | The maximum sync latency in the last 30 seconds. |
Procedure
Run the following command to view the performance information about the LSM data partition:
zbs-perf-tools chunk lsm partition [--chunk-addr <ip>]
| Parameter | Description |
|---|---|
--chunk-addr <ip> | The zbs-chunkd RPC server address. Default: 127.0.0.1:10200, the chunk on the node where the command is run. |
Output example
$zbs-perf-tools chunk lsm partition
PATH R/S READ BW READ LAT READ MAX LAT W/S WRITE BW WRITE LAT WRITE MAX LAT SYNC/S SYNC LAT SYNC MAX LAT
-------------------------------------------------------------------------------------------------------------------------------------------------------
/dev/sdb1 18.00 4.72 MB/s(4.50 MiB/s) 7.88 MS 17.95 MS 0.00 0.00 B/s(0.00 B/s) 0.00 NS 0.00 NS 0.00 0.00 NS 0.00 NS
/dev/sdc1 18.00 4.72 MB/s(4.50 MiB/s) 5.59 MS 12.85 MS 0.00 0.00 B/s(0.00 B/s) 0.00 NS 0.00 NS 0.00 0.00 NS 0.00 NS
/dev/sdd1 18.00 4.72 MB/s(4.50 MiB/s) 4.20 MS 9.42 MS 0.00 0.00 B/s(0.00 B/s) 0.00 NS 0.00 NS 0.00 0.00 NS 0.00 NS
/dev/sde1 18.00 4.72 MB/s(4.50 MiB/s) 7.77 MS 15.62 MS 0.00 0.00 B/s(0.00 B/s) 0.00 NS 0.00 NS 0.00 0.00 NS 0.00 NS Output note
| Parameter | Description |
|---|---|
PATH | The data partition. |
R/S | The read IOPS in the last 1 second. |
READ BW | The read I/O bandwidth in the last 1 second. |
READ LAT | The average read I/O latency in the last 1 second. |
READ MAX LAT | The maximum read I/O latency in the last 30 seconds. |
W/S | The write IOPS in the last 1 second. |
WRITE BW | The write I/O bandwidth in the last 1 second. |
WRITE LAT | The average write I/O latency in the last 1 second. |
WRITE MAX LAT | The maximum write I/O latency in the last 30 seconds. |
SYNC/S | The number of syncs in the last 1 second. |
SYNC LAT | The average sync latency in the last 1 second. |
SYNC MAX LAT | The maximum sync latency in the last 30 seconds. |