Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Direct I/O #168

Open
tabokie opened this issue Dec 8, 2021 · 5 comments
Open

Support Direct I/O #168

tabokie opened this issue Dec 8, 2021 · 5 comments
Labels
enhancement New feature or request

Comments

@tabokie
Copy link
Member

tabokie commented Dec 8, 2021

Simple benchmark shows more than 20% throughput improvement from direct I/O.

This task is preferred to be stacked over #165.

@tabokie tabokie added the enhancement New feature or request label Dec 8, 2021
@sticnarf
Copy link
Contributor

Besides direct I/O, is there plan to use Linux AIO and provide asynchronous read and write interfaces in the near future?

@tabokie
Copy link
Member Author

tabokie commented Jan 20, 2022

No plan yet. But I think it would be trivial to implement once this task (and parallel writing) is completed.

@sticnarf
Copy link
Contributor

sticnarf commented Jan 21, 2022

For direct I/O, I think one thing we should do before GA is change the file header to occupy the whole 4K block. I think it will be helpful to forward compatibility, so we don't need a format v2 to support direct I/O.

@tabokie
Copy link
Member Author

tabokie commented Jan 21, 2022

@sticnarf Sadly, we will default enable it for TiDB Cloud dev tier. Can't change it now.

@LykxSassinator
Copy link
Contributor

LykxSassinator commented Mar 12, 2024

Unfortunately, while this enhancement may yield positive results in other scenarios, its impact on TiKV is not as significant.

Based on practical statistics gathered from TiKV across various workloads such as sysbench, tpcc, and ycsb, it has been observed that the typical size during the flushing of raft logs is less than 8kb/s. Consequently, the benefits of introducing DIO are not as impressive as initially expected.

workloads Bytes per second pic
tpcc-1k avg 3KB/s (P99 < 16KB/s) image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants