FAQ - What is the purpose of setting the disk scheduler?

The Aerospike Knowledge Base has moved to https://support.aerospike.com. Content on https://discuss.aerospike.com is being migrated to either https://support.aerospike.com or https://docs.aerospike.com. Maintenance on articles stored in this repository ceased on December 31st 2022 and this article may be stale. If you have any questions, please do not hesitate to raise a case via https://support.aerospike.com.

FAQ - What is the purpose of setting the disk scheduler?

Details

Aerospike database allows for persistent storage through the use of HDD or SSD drives. I/O schedulers can improve performance of slower storage devices with limited queueing. I/O schedulers can reorder and prioritize disk I/O requests. Particularly useful in HDD drives that are mechanical and use a lot of seeking to read and write data.

PCIe devices (NVMe SSD drives) have their own large internal queues along with fast service and do not require or benefit from setting an I/O scheduler.

Errors

In versions of aerospike prior to 3.10.1 the following error would be generated in the logs for nvme devices:

Sep 23 2016 14:08:55 GMT: WARNING (drv_ssd): (drv_ssd.c:3478) storage: couldn't open /sys/block/nvme0n/queue/scheduler, did not set scheduler mode: No such file or directory

Sep 23 2016 14:08:55 GMT: WARNING (drv_ssd): (drv_ssd.c:3478) storage: couldn't open /sys/block/nvme1n/queue/scheduler, did not set scheduler mode: No such file or directory

This error was benign and could have been ignored. Aerospike tried to set scheduler on an NVME drive that does not support a scheduler and is by default set to none.

Different type of schedulers

There exist 3 types of disk I/O scheduler’s that can be set for disk devices.

A disk device IO scheduler could be configured to one of the following values:

  • noop : Recommended when using aerospike with non-nvme drives, SSD or HDD. The noop scheduler does not perform any I/O requests sorting and only does merging of I/O requests.

  • deadline : The deadline I/O Scheduler is a lightweight scheduler which enforces a soft deadline on I/O requests.

  • cfq : The Complete Fair Queuing (CFQ) I/O Scheduler tries to maintain system-wide fairness of I/O bandwidth

For NVMe drives, it is recommended to have no explicit scheduler-mode configuration parameter.

Reference

Keywords

Scheduler noop nvme

Timestamp

11/17/2016