Changing the I/O scheduler for a specific disk
Solution 1:
The tuned
and tuned-utils
pacakages are available for Fedora (they are also in Red Hat). This is a system service that can apply predefined or user-defined system profiles and tuneables on-the-fly, including mount options, disk schedulers, sysctl parameters, etc. Many Liinux admins overlook these settings.
See the Fedora 20 Manual:
http://docs.fedoraproject.org/en-US/Fedora/20/html/Power_Management_Guide/sect-tuned-installation-and-usage.html
Something like:
tuned-adm profile virtual-guest
or
tuned-adm profile enterprise-storage
Here's the schedule of settings for RHEL. Fedora may be slightly different.
I know you're looking for settings on a specific disk, but I tend to apply the I/O scheduling parameters to all of the disks. Either way, see if the predefined profiles work for you (no need to duplicate effort). If not, the profiles are easy to customize.
Solution 2:
You simply have to create a file in /etc/systemd/system/io-scheduler.service with the following content:
[Unit]
Description=I/O Scheduler Setter
After=local-fs.target
[Service]
Type=oneshot
ExecStart=/bin/bash -c 'echo noop > /sys/block/sda/queue/scheduler'
TimeoutSec=0
RemainAfterExit=yes
[Install]
WantedBy=multi-user.target
Then, enable the service for auto start at boot and start it for the current session with:
chmod 755 /etc/systemd/system/io-scheduler.service
systemctl enable io-scheduler.service
systemctl start io-scheduler.service