Last active
March 3, 2023 13:21
-
-
Save CHERTS/ae77e06eb46f59011b219a25395fdd41 to your computer and use it in GitHub Desktop.
Get Linux i/o scheduler and params
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for i in $(ls -1 /sys/block/ | grep -oE 'sd[a-z]|nvme.*'); do echo -n "$i: rotational: $(cat /sys/block/$i/queue/rotational) | \ | |
scheduler: $(cat /sys/block/$i/queue/scheduler) | \ | |
nr_requests: $(cat /sys/block/$i/queue/nr_requests) | \ | |
rq_affinity: $(cat /sys/block/$i/queue/rq_affinity)"; [ -f "/sys/block/$i/queue/read_ahead_kb" ] && echo -n " | read_ahead_kb: $(cat /sys/block/$i/queue/read_ahead_kb)"; [ -f "/sys/block/$i/queue/iosched/writes_starved" ] && echo -n " | writes_starved: $(cat /sys/block/$i/queue/iosched/writes_starved)"; [ -f "/sys/block/$i/queue/iosched/read_expire" ] && echo -n " | read_expire: $(cat /sys/block/$i/queue/iosched/read_expire)"; echo ""; done #| awk '!(NR%2){print p "\t\t\t" $0}{p=$0}' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment