By default Linux distros are unoptimized in terms of I/O latency. So, here are some tips to improve that.
The performance can be checked by:
fio --name=read --readonly --rw={read/randread} --ioengine=libaio --iodepth={jobs_per_each_worker's_command} --bs={4k/2M} --direct={0/1} --numjobs=<number_of_parallel_workers> --runtime={10/30/60} --group_reporting --filename=/dev/nvme<device>
- to simulate an optimized app;dd_rescue /dev/nvme<device> /dev/null -b {4k/2M} {-d}
- to simulate a stupid app.
Appropriate settings are changed in appropriate places, such as:
/etc/tuned/<custom-profile>/tuned.conf
: