Linux elevators (Re: BFQ: simple elevator)

Raymond Jennings shentino at gmail.com
Wed Mar 20 21:00:34 EDT 2013


On Wed, Mar 20, 2013 at 4:45 PM, Arlie Stephens <arlie at worldash.org> wrote:
> On Mar 20 2013, Valdis.Kletnieks at vt.edu wrote:
>> On Wed, 20 Mar 2013 16:05:09 -0700, Arlie Stephens said:
>> > The ongoing thread reminds me of a simple question I've had since I
>> > first read about linux' mutiple I/O schedulers. Why is the choice of
>> > I/O scheduler global to the whole kernel, rather than per-device or
>> > similar?
>>
>> They aren't global to the kernel.
>
> Thanks for the correction. It appears I got wrong (outdated?)
> information from some book on kernel development, or perhaps simply
> misunderstood what I read.

Yeah, the "global" thing is just the system default.

It's what newly created or discovered block devices will be assigned initially.

> When I tried the example you gave, I saw the same thing, even on
> the older kernels I'm working with (2.6.32 in particular).
>
>
>>
>> On my laptop:
>>
>> # find /sys/devices/pci* -name 'scheduler' | xargs grep .
>> /sys/devices/pci0000:00/0000:00:1f.2/ata1/host0/target0:0:0/0:0:0:0/block/sda/queue/scheduler:noop deadline [cfq]
>> /sys/devices/pci0000:00/0000:00:1f.2/ata2/host1/target1:0:0/1:0:0:0/block/sr0/queue/scheduler:noop deadline [cfq]
>> # echo noop >| /sys/devices/pci0000:00/0000:00:1f.2/ata2/host1/target1:0:0/1:0:0:0/block/sr0/queue/schedule
>> # find /sys/devices/pci* -name 'scheduler' | xargs grep .
>> /sys/devices/pci0000:00/0000:00:1f.2/ata1/host0/target0:0:0/0:0:0:0/block/sda/queue/scheduler:noop deadline [cfq]
>> /sys/devices/pci0000:00/0000:00:1f.2/ata2/host1/target1:0:0/1:0:0:0/block/sr0/queue/scheduler:[noop] deadline cfq
>>
>> I just changed the scheduler for the CD-ROM.
>
> --
> Arlie
>
> (Arlie Stephens                                  arlie at worldash.org)
>
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies at kernelnewbies.org
> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies



More information about the Kernelnewbies mailing list