Hi, I have a startup script that changes the default IO schedulers but it does not have any effect, however if I paste the commands into a terminal they work fine, which means the script is not running at all I think.
I have put the script in /etc/rc.d/rc.local and made it executable
script contents: work.sh
#!/bin/sh
echo deadline > /sys/block/sda/queue/scheduler
echo deadline > /sys/block/sdc/queue/scheduler
echo deadline > /sys/block/sdd/queue/scheduler
echo 10 > /sys/block/sda/queue/iosched/read_expire
echo 9 > /sys/block/sda/queue/iosched/writes_starved
i’m running fedora 19 on the latest kernel.
is the rc-local service running ?
What’s the output from:
systemctl status rc-local
You might want to see here:
https://ask.fedoraproject.org/question/9210/auto-running-two-commands-at-boot/
the service fails after starting it:
systemctl status rc-local
rc-local.service - /etc/rc.d/rc.local Compatibility
Loaded: loaded (/usr/lib/systemd/system/rc-local.service; static)
Active: inactive (dead)
start condition failed at Wed 2013-08-07 20:00:46 BST; 25s ago
I dont have any files in /etc/rc.d/rc.local so I cant understand why it is failing.
ls -l /etc/rc.local produces>
total 4
-rwxrwxr-x 1 root root 258 Jul 17 14:33 setDevices.sh
which contains>
#!/bin/sh
echo deadline > /sys/block/sda/queue/scheduler
echo deadline > /sys/block/sdc/queue/scheduler
echo deadline > /sys/block/sdd/queue/scheduler
echo 10 > /sys/block/sda/queue/iosched/read_expire
echo 9 > /sys/block/sda/queue/iosched/writes_starved
SeZo
August 10, 2013, 9:23pm
6
Have you tried to put your script into /etc/rc.d/rc.local