5 ms·
This use of dt, etc, is pretty cool, and I understand the point of this this blog entry was an exploration of those tools. But in the wider world of SSD perfor
by IvyMike 4y ago
This use of dt, etc, is pretty cool, and I understand the point of this this blog entry was an exploration of those tools.
But in the wider world of SSD performance, you're going to want more. fio (written by Jens Axboe, who's responsible for a lot of the I/O subsystem in Linux) is the standard tool used to do benchmarking, has tons of options to control I/O mix and parallelism, captures both thruput and latency numbers, with lots of switches to control exactly what data is collected. https://github.com/axboe/fio https://github.com/axboe/fio
"Something weird going on with the 1K bucket landing at the bottom." The SSD's Flash Translation Layer will occasionally do both caching and garbage collection, leading to the weird extreme long latency outlier. The long spike at 1K is weird, but note that optimal internal write size of the SSD is probably something like 64K or 128K these days. Different SSDs will have different FTL algorithms, different overprovisioning, different internal parallelism, etc, so it can be very tricky predict actual real-life performance. https://en.wikipedia.org/wiki/Flash_memory_controller https://en.wikipedia.org/wiki/Flash_memory_controller
- mgerdts 4y agoI think the 1k bucket statement was referring to the sort order. That bucket represents about 1 to 2 microseconds, which is dubiously fast. Maybe this is possible if the IO is serviced by DRAM on the NVMe controller. Maybe the IOs in question completed without going to the drive, such as in some error condition. There are also a bunch of IOs in the 0 bucket. I’m not sure how you make it from sdstrategy to sd_buf_done with the passage of no time. Perhaps the granularity if the nsecs variable’s values is rather coarse.
- yakubin 4y agoUsing just fio without kernel tracing, you run the risk of testing the filesystem instead of the storage medium. You could use fio to fabricate I/O operations, but the measurements coming from tracing are more trustworthy than the userspace measurements fio makes (unless fio does some in-kernel measurements I don't know about).
- IvyMike 4y agoRegarding measuring to avoid profiling the filesystem: You can run fio against the raw block device to avoid this.