-
Notifications
You must be signed in to change notification settings - Fork 6
/
clr-power-tweaks.conf
93 lines (84 loc) · 3.99 KB
/
clr-power-tweaks.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
#
# Clear Linux Project for Intel Architecture Power tweaks
#
# Copyright (C) 2012-2015 Intel Corporation
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, version 3 of the License.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
# Authors:
# Arjan van de Ven <[email protected]>
# Dimitri John Ledkov <[email protected]>
#
# Type Path Mode UID GID Age Argument
#
# --BEGIN--
# synchronous dirty ratio --> 50%
w /proc/sys/vm/dirty_ratio - - - - 50
w /proc/sys/kernel/unprivileged_bpf_disabled - - - - 1
# start IO at 5% not 10%... start IO a little earlier asynchronously, since memory sizes are bigger now
w /proc/sys/vm/dirty_background_ratio - - - - 5
# 15 seconds before the VM starts writeback, allowing the FS to deal with this better
w /proc/sys/vm/dirty_writeback_centisecs - - - - 1500
w /proc/sys/vm/swappiness - - - - 10
w /sys//kernel/mm/transparent_hugepage/khugepaged/scan_sleep_millisecs - - - - 30000
w /sys/devices/virtual/graphics/fbcon/cursor_blink - - - - 0
w /sys/kernel/rcu_expedited - - - - 0
w /proc/sys/vm/mmap_min_addr - - - - 65536
# oom less
w /proc/sys/vm/extfrag_threshold - - - - 100
w /sys/kernel/mm/ksm/sleep_millisecs - - - - 4000
# w /sys/kernel/mm/ksm/run - - - - 1
w /sys/kernel/mm/ksm/pages_to_scan - - - - 1000
w /proc/sys/net/core/rmem_max - - - - 1703936
w /proc/sys/net/core/wmem_max - - - - 1703936
w /proc/sys/net/core/somaxconn - - - - 512
# This tuneable decides the minimum time a task will be be allowed to
# run on CPU before being pre-empted out
w /proc/sys/kernel/sched_min_granularity_ns - - - - 2250000
w /proc/sys/kernel/sched_migration_cost_ns - - - - 50000
# Ability of tasks being woken to preempt the current task
w /proc/sys/kernel/sched_wakeup_granularity_ns - - - - 15000000
# audio pm
w /sys/module/snd_hda_intel/parameters/power_save - - - - 1
# P state stuff
w /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor - - - - performance
# we want at least half performance, this helps us in race-to-halt and
# to give us reasonable responses
w /sys/devices/system/cpu/intel_pstate/min_perf_pct - - - - 50
w /proc/sys/net/core/default_qdisc - - - - fq
# Disable acceptance of all ICMP redirected packets on all interfaces.
w /proc/sys/net/ipv4/conf/all/accept_redirects - - - - 0
w /proc/sys/net/ipv6/conf/all/accept_redirects - - - - 0
w /proc/sys/net/ipv4/conf/default/accept_redirects - - - - 0
w /proc/sys/net/ipv6/conf/default/accept_redirects - - - - 0
# Disables sending of all IPv4 ICMP redirected packets on all interfaces.
w /proc/sys/net/ipv4/conf/all/send_redirects - - - - 0
w /proc/sys/net/ipv4/conf/default/send_redirects - - - - 0
# Disables acceptance of secure ICMP redirected packets on all interfaces.
w /proc/sys/net/ipv4/conf/all/secure_redirects - - - - 0
w /proc/sys/net/ipv4/conf/default/secure_redirects - - - - 0
# SATA link power management
w /sys/class/scsi_host/*/link_power_management_policy - - - - med_power_with_dipm
# Performance tuning for SATA and NVME storage
w /sys/block/sd*/queue/scheduler - - - - mq-deadline
w /sys/block/sd*/queue/nr_requests - - - - 1024
w /sys/block/sd*/queue/read_ahead_kb - - - - 1024
w /sys/block/sd*/queue/add_random - - - - 1
w /sys/block/nvme*/queue/scheduler - - - - mq-deadline
w /sys/block/nvme*/queue/nr_requests - - - - 2048
w /sys/block/nvme*/queue/read_ahead_kb - - - - 256
w /sys/block/nvme*/queue/add_random - - - - 1
# Enable turbo mode max
w /proc/sys/kernel/sched_itmt_enabled - - - - 1
# Reload the microcode at boot
w /sys/devices/system/cpu/microcode/reload - - - - 1