Scheduling algorithms, sometimes referred to as elevators[47], are methods used by the operating system to decide the order in which block I/O operations (read/write) take place. Different algorithms exist because no single one is best suited for all workloads.
A database server would want to prioritize latency over throughput, thus making the deadline scheduler an ideal choice, whereas in an interactive desktop you would favor the CFQ (“completely fair queueing”) scheduler. Workload isn't the only parameter to consider when selecting a scheduler. The properties of the backing storage device also play an important role (SSD or spinning disk?). In a virtualized environment the choice of scheduler becomes even more involved because you may wish to consider the scheduler used by the hypervisor as well.
As you can see, the topic of selecting the proper I/O scheduler is neither short, nor is it simple. That being said, in this chapter I'll attempt to provide you with sufficient information to make an informed decision as well as several resources which discuss I/O schedulers in greater detail. Together we'll review the scheduler options available, the procedure for setting one permanently, and typical use cases.
White papers:
“Does Virtualization Make Disk Scheduling Passé?” - http://www-users.cs.umn.edu/~chandra/papers/hotstorage09/paper.pdf
“On Disk I/O Scheduling in Virtual Machines” - http://sysrun.haifa.il.ibm.com/hrl/wiov2010/papers/kesavan.pdf
“Understanding the Effects of Hypervisor I/O Scheduling for Virtual Machine Performance Interference” - http://www.seas.gwu.edu/~howie/publications/CloudCom12.pdf
I/O Scheduling for SAN and Virtualization - http://www.monperrus.net/martin/IO+scheduling+for+san+and+virtualization
Performance tests:
Ceph Bobtail Performance – IO Scheduler Comparison - http://ceph.com/community/ceph-bobtail-performance-io-scheduler-comparison/
I/O Scheduler Comparison On The Linux 3.4 Desktop - http://www.phoronix.com/scan.php?page=article&item=linux_iosched_2012&num=1