You are not logged in.

#1 2009-11-10 05:40:03

steve_v
Member
Registered: 2006-02-11
Posts: 80

Anyone know how to set IO scheduler via udev?

USB storage devices seem slow on the default (CFQ) scheduler, I am looking for a way to set /sys/block/sd[X]/que/scheduler to noop when a new USB storage device is plugged in.
Found some limited info on the WWW but I can't seem to get it to trigger even a test command when the drive is plugged in.
Anyone good with udev rules? most of the info i can find appears somewhat outdated.

Cheers,

Steve.

Offline

#2 2017-02-12 03:04:00

technojoe
Member
Registered: 2017-02-12
Posts: 1

Re: Anyone know how to set IO scheduler via udev?

# /etc/udev/rules.d/60-usb-storage.rules
# set deadline scheduler for usb-storage devices
ACTION=="add|change", KERNEL=="sd[a-z]", SUBSYSTEM=="block", DEVPATH=="*usb*", ATTR{queue/scheduler}="deadline"

Disclaimer: Works for me on my devices. I don't know if it causes regressions on other devices.

Offline

#3 2017-02-12 06:31:43

steve_v
Member
Registered: 2006-02-11
Posts: 80

Re: Anyone know how to set IO scheduler via udev?

Holy necro batman wink
Thanks for the info, I'm actually running Debian these days, and the issue I was trying to workaround is no more... but I'll file this for future reference.

Offline

#4 2017-02-12 17:21:11

R00KIE
Forum Fellow
From: Between a computer and a chair
Registered: 2008-09-14
Posts: 4,734

Re: Anyone know how to set IO scheduler via udev?

No necro-bumping.

Closing.


R00KIE
Tm90aGluZyB0byBzZWUgaGVyZSwgbW92ZSBhbG9uZy4K

Offline

Board footer

Powered by FluxBB