forked from pool/systemd
Accepting request 592117 from home:develop7:branches:Base:System
- Enhance IO scheduler tweaking rules to support blk-mq as well * Set optimal blk-mq schedulers (bfq and mq-deadline for HDD and SSD respectively) * Explicitly set CFQ for rotational disks when no `elevator` is specified * Verbose comments explaining what is going on * Rename the rules file since it is not ssd-only anymore OBS-URL: https://build.opensuse.org/request/show/592117 OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=1026
This commit is contained in:
parent
a95d199871
commit
fff9c3b6a1
24
60-io-scheduler.rules
Normal file
24
60-io-scheduler.rules
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
# Set optimal IO schedulers for HDD and SSD
|
||||||
|
|
||||||
|
ACTION!="add", GOTO="scheduler_end"
|
||||||
|
SUBSYSTEM!="block", GOTO="scheduler_end"
|
||||||
|
|
||||||
|
# Do not change scheduler if `elevator` cmdline parameter is set
|
||||||
|
IMPORT{cmdline}="elevator"
|
||||||
|
ENV{elevator}=="*?", GOTO="scheduler_end"
|
||||||
|
|
||||||
|
# Determine if BLK-MQ is enabled
|
||||||
|
TEST=="%S%p/mq", ENV{.IS_MQ}="1"
|
||||||
|
|
||||||
|
# MQ: BFQ scheduler for HDD
|
||||||
|
ENV{.IS_MQ}=="1", ATTR{queue/rotational}!="0", ATTR{queue/scheduler}="bfq"
|
||||||
|
# MQ: deadline scheduler for SSD
|
||||||
|
ENV{.IS_MQ}=="1", ATTR{queue/rotational}=="0", ATTR{queue/scheduler}="mq-deadline"
|
||||||
|
|
||||||
|
# Non-MQ: CFQ scheduler for HDD
|
||||||
|
ENV{.IS_MQ}!="1", ATTR{queue/rotational}!="0", ATTR{queue/scheduler}="cfq"
|
||||||
|
# Non-MQ: deadline scheduler for SSD
|
||||||
|
ENV{.IS_MQ}!="1", ATTR{queue/rotational}=="0", ATTR{queue/scheduler}="deadline"
|
||||||
|
|
||||||
|
LABEL="scheduler_end"
|
||||||
|
|
@ -1,11 +0,0 @@
|
|||||||
# do not edit this file, it will be overwritten on update
|
|
||||||
|
|
||||||
ACTION!="add", GOTO="ssd_scheduler_end"
|
|
||||||
SUBSYSTEM!="block", GOTO="ssd_scheduler_end"
|
|
||||||
|
|
||||||
IMPORT{cmdline}="elevator"
|
|
||||||
ENV{elevator}=="*?", GOTO="ssd_scheduler_end"
|
|
||||||
|
|
||||||
KERNEL=="sd*[!0-9]", ATTR{queue/rotational}=="0", ATTR{queue/scheduler}="deadline"
|
|
||||||
|
|
||||||
LABEL="ssd_scheduler_end"
|
|
@ -62,6 +62,18 @@ Wed Mar 28 11:58:10 UTC 2018 - fbui@suse.com
|
|||||||
|
|
||||||
- Split systemd-coredump sub-package off (bsc#1083849)
|
- Split systemd-coredump sub-package off (bsc#1083849)
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Mar 27 20:15:06 UTC 2018 - develop7@develop7.info
|
||||||
|
|
||||||
|
- Enhance IO scheduler tweaking rules to support blk-mq as well
|
||||||
|
|
||||||
|
* Set optimal blk-mq schedulers (bfq and mq-deadline for HDD and
|
||||||
|
SSD respectively)
|
||||||
|
* Explicitly set CFQ for rotational disks when no `elevator`
|
||||||
|
is specified
|
||||||
|
* Verbose comments explaining what is going on
|
||||||
|
* Rename the rules file since it is not ssd-only anymore
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Mar 27 15:58:34 UTC 2018 - fbui@suse.com
|
Tue Mar 27 15:58:34 UTC 2018 - fbui@suse.com
|
||||||
|
|
||||||
|
@ -152,7 +152,7 @@ Source101: scripts-systemd-upgrade-from-pre-210.sh
|
|||||||
Source102: scripts-systemd-migrate-sysconfig-i18n.sh
|
Source102: scripts-systemd-migrate-sysconfig-i18n.sh
|
||||||
Source200: scripts-udev-convert-lib-udev-path.sh
|
Source200: scripts-udev-convert-lib-udev-path.sh
|
||||||
|
|
||||||
Source1000: 60-ssd-scheduler.rules
|
Source1000: 60-io-scheduler.rules
|
||||||
Source1001: 80-hotplug-cpu-mem.rules
|
Source1001: 80-hotplug-cpu-mem.rules
|
||||||
Source1002: 99-wakeup-from-idle.rules
|
Source1002: 99-wakeup-from-idle.rules
|
||||||
|
|
||||||
@ -497,7 +497,7 @@ install -m0755 -D %{S:3} %{buildroot}/%{_sbindir}/systemd-sysv-convert
|
|||||||
install -m0755 -D %{S:12} %{buildroot}/%{_prefix}/lib/systemd/systemd-sysv-install
|
install -m0755 -D %{S:12} %{buildroot}/%{_prefix}/lib/systemd/systemd-sysv-install
|
||||||
|
|
||||||
# The rules that we shouldn't maintain
|
# The rules that we shouldn't maintain
|
||||||
install -m0644 -D %{S:1000} %{buildroot}%{_udevrulesdir}/60-ssd-scheduler.rules
|
install -m0644 -D %{S:1000} %{buildroot}%{_udevrulesdir}/60-io-scheduler.rules
|
||||||
install -m0644 -D %{S:1001} %{buildroot}%{_udevrulesdir}/80-hotplug-cpu-mem.rules
|
install -m0644 -D %{S:1001} %{buildroot}%{_udevrulesdir}/80-hotplug-cpu-mem.rules
|
||||||
install -m0644 -D %{S:1002} %{buildroot}%{_udevrulesdir}/99-wakeup-from-idle.rules
|
install -m0644 -D %{S:1002} %{buildroot}%{_udevrulesdir}/99-wakeup-from-idle.rules
|
||||||
|
|
||||||
|
@ -62,6 +62,18 @@ Wed Mar 28 11:58:10 UTC 2018 - fbui@suse.com
|
|||||||
|
|
||||||
- Split systemd-coredump sub-package off (bsc#1083849)
|
- Split systemd-coredump sub-package off (bsc#1083849)
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Mar 27 20:14:41 UTC 2018 - develop7@develop7.info
|
||||||
|
|
||||||
|
- Enhance IO scheduler tweaking rules to support blk-mq as well
|
||||||
|
|
||||||
|
* Set optimal blk-mq schedulers (bfq and mq-deadline for HDD and
|
||||||
|
SSD respectively)
|
||||||
|
* Explicitly set CFQ for rotational disks when no `elevator`
|
||||||
|
is specified
|
||||||
|
* Verbose comments explaining what is going on
|
||||||
|
* Rename the rules file since it is not ssd-only anymore
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Mar 27 15:58:34 UTC 2018 - fbui@suse.com
|
Tue Mar 27 15:58:34 UTC 2018 - fbui@suse.com
|
||||||
|
|
||||||
|
@ -150,7 +150,7 @@ Source101: scripts-systemd-upgrade-from-pre-210.sh
|
|||||||
Source102: scripts-systemd-migrate-sysconfig-i18n.sh
|
Source102: scripts-systemd-migrate-sysconfig-i18n.sh
|
||||||
Source200: scripts-udev-convert-lib-udev-path.sh
|
Source200: scripts-udev-convert-lib-udev-path.sh
|
||||||
|
|
||||||
Source1000: 60-ssd-scheduler.rules
|
Source1000: 60-io-scheduler.rules
|
||||||
Source1001: 80-hotplug-cpu-mem.rules
|
Source1001: 80-hotplug-cpu-mem.rules
|
||||||
Source1002: 99-wakeup-from-idle.rules
|
Source1002: 99-wakeup-from-idle.rules
|
||||||
|
|
||||||
@ -495,7 +495,7 @@ install -m0755 -D %{S:3} %{buildroot}/%{_sbindir}/systemd-sysv-convert
|
|||||||
install -m0755 -D %{S:12} %{buildroot}/%{_prefix}/lib/systemd/systemd-sysv-install
|
install -m0755 -D %{S:12} %{buildroot}/%{_prefix}/lib/systemd/systemd-sysv-install
|
||||||
|
|
||||||
# The rules that we shouldn't maintain
|
# The rules that we shouldn't maintain
|
||||||
install -m0644 -D %{S:1000} %{buildroot}%{_udevrulesdir}/60-ssd-scheduler.rules
|
install -m0644 -D %{S:1000} %{buildroot}%{_udevrulesdir}/60-io-scheduler.rules
|
||||||
install -m0644 -D %{S:1001} %{buildroot}%{_udevrulesdir}/80-hotplug-cpu-mem.rules
|
install -m0644 -D %{S:1001} %{buildroot}%{_udevrulesdir}/80-hotplug-cpu-mem.rules
|
||||||
install -m0644 -D %{S:1002} %{buildroot}%{_udevrulesdir}/99-wakeup-from-idle.rules
|
install -m0644 -D %{S:1002} %{buildroot}%{_udevrulesdir}/99-wakeup-from-idle.rules
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user