Re:I/O Is Faster Than CPU – Let’s Partition Resources and El...
by briffle on Friday May 03, 2019 @01:14PM
(#19820229)
Postgresql allows you to tune the 'cost' of sequential and random IO, to help the planner figure out the best way to get the data.
https://www.postgresql.org/docs/11/runtime-config-query.html...
Re:I/O Is Faster Than CPU – Let’s Partition Resources and El...
by dorlaor on Friday May 03, 2019 @01:43PM
(#19820521)
With LSM approach (log structured merge tree) we have at Scylla, we make all the writes batched/sequential and receive an awesome boost.
Some reads can be sequential too if you scan through the clustering keys.
But even if SSDs do blow HDDs out the water on sequential IO, it's on random IO that the difference is most stark, the cost difference between sequential and random is much lower on SSD than on HDDs, and both random IO throughput and random IOPS shoot through the roof relative to spinning rust.
An SSD might be an order of magnitude better than an HDD on sequential IO, but will often be 2 or 3 on random IO. That means the loss of throughput from sequential IO to random IO (while still there due to commands overhead and the like) is much, much, much smaller on an SSD than on an HDD. And the story is similar on the latency front, an HDD might have a command latency in the low tens milliseconds, an SSD in the low-mid tens microseconds.