1THINKFAN(1) thinkfan THINKFAN(1)
2
3
4
6 thinkfan - A simple fan control program
7
9 thinkfan [-hnqzDd] [-b BIAS] [-c CONFIG] [-s SECONDS] [-p [DELAY]]
10
11
12
13
15 Thinkfan sets the fan speed according to temperature limits set in the
16 config file. It can read temperatures from a number of sources:
17
18
19 /proc/acpi/ibm/thermal
20 Which is provided by the thinkpad_acpi kernel module on older
21 Thinkpads,
22
23
24 temp*_input files in sysfs
25 Which may be provided by any hwmon drivers, including
26 thinkpad_acpi on modern Thinkpads,
27
28
29 Hard disks with S.M.A.R.T. support
30 With the help of libatasmart, if thinkfan was compiled with
31 -DUSE_ATASMART=ON
32
33
34 From the proprietary nVidia driver
35 When the proprietary nVidia driver is used, no hwmon for the
36 card will be available. In this situation, thinkfan can use the
37 proprietary NVML API to get temperatures.
38
39
40 The fan can be /proc/acpi/ibm/fan or some PWM file in /sys/class/hwmon.
41 See thinkfan.conf(5) for a detailed explanation of the config syntax.
42
43
44 WARNING: This program does only very basic sanity checking on the con‐
45 figuration. That means that you can set your temperature limits
46 as insane as you like.
47
48 There are two general modes of operation:
49
50
51
52 COMPLEX MODE
53 In complex mode, temperature limits are defined for each sensor think‐
54 fan knows about. Setting suitable limits for each sensor in your system
55 will probably require a bit of experimentation and good knowledge about
56 your hardware, but it's the safest way of keeping each component within
57 its specified temperature range. See
58 http://www.thinkwiki.org/wiki/Thermal_Sensors for details on which sen‐
59 sor measures what temperature in a Thinkpad. On other systems you'll
60 have to find out on your own. See the example configs to learn about
61 the syntax.
62
63
64
65 SIMPLE MODE
66 In simple mode, Thinkfan uses only the highest temperature found in the
67 system. That may be dangerous, e.g. for hard disks. That's why you
68 should provide a correction value (i.e. add 10-15 °C) for the sensor
69 that has the temperature of your hard disk (or battery...). See the
70 example config files for details about that.
71
72
73
74
76 Some example configurations are provided with the source package. For a
77 detailed see the config man page thinkfan.conf(5).
78
79
80
81
83 -h Show a short help message
84
85
86 -s SECONDS
87 Maximum seconds between temperature updates (default: 5)
88
89
90 -b BIAS
91 Floating point number (-10 to 30) to control rising temperature
92 exaggeration. If the temperature increases by more than 2 °C
93 during one cycle, this number is used to calculate a bias, which
94 is added to the current highest temperature seen in the system:
95
96 current_tmax = current_tmax + delta_t * BIAS / 10
97
98 This means that negative numbers can be used to even out short
99 and sudden temperature spikes like those seen on some on-DIE
100 sensors. Use DANGEROUS mode to remove the -10 to +30 limit. Note
101 that you can't have a space between -b and a negative argument,
102 because otherwise getopt will interpret things like -10 as an
103 option and fail (i.e. write -b-10 instead of -b -10).
104
105 Default is 15.0
106
107
108 -c FILE
109 Load a different configuration file. By default, thinkfan first
110 tries to load /etc/thinkfan.yaml, and /etc/thinkfan.conf after
111 that. The former must be in YAML format, while the latter can
112 be either YAML or the old legacy syntax.
113
114 If this option is specified, thinkfan attempts to load the con‐
115 fig only from FILE. If its name ends in “.yaml”, it must be in
116 YAML format. Otherwise, it can be either YAML or legacy syntax.
117 See thinkfan.conf(5) and thinkfan.conf.legacy(5) for details.
118
119
120 -n Do not become a daemon and log to terminal instead of syslog
121
122
123 -q Be quiet, i.e. reduce logging level from the default. Can be
124 specified multiple times until only errors are displayed/logged.
125
126
127 -v Be more verbose. Can be specified multiple times until every
128 message is displayed/logged.
129
130
131 -p [SECONDS]
132 Use the pulsing-fan workaround (for older Thinkpads). Takes an
133 optional floating-point argument (0-10s) as depulsing duration.
134 Default 0.5s.
135
136
137 -d Do not read temperature from sleeping disks. Instead, 0 °C is
138 used as that disk's temperature. This is needed if reading the
139 temperature causes your disk to wake up unnecessarily. NOTE:
140 This option is only available if thinkfan was built with -D
141 USE_ATASMART.
142
143
144 -D DANGEROUS mode: Disable all sanity checks. May damage your hard‐
145 ware!!
146
148 SIGINT and SIGTERM simply interrupt operation and should cause thinkfan
149 to terminate cleanly.
150
151 SIGHUP makes thinkfan reload its config. If there's any problem with
152 the new config, we keep the old one.
153
154 SIGUSR1 causes thinkfan to dump all currently known temperatures either
155 to syslog, or to the console (if running with the -n option).
156
158 0 Normal exit
159
160
161 1 Runtime error
162
163
164 2 Unexpected runtime error
165
166
167 3 Invalid commandline option
168
169
170
171
173 The thinkfan config manpage:
174 thinkfan.conf(5)
175
176 Example configs shipped with the source distribution, also available at:
177 https://github.com/vmatare/thinkfan/tree/master/examples
178
179 The Linux hwmon user interface documentation:
180 https://www.kernel.org/doc/html/latest/hwmon/sysfs-interface.html
181
182 The thinkpad_acpi interface documenation:
183 https://www.kernel.org/doc/html/latest/admin-guide/laptops/thinkpad-acpi.html
184
185
186
187
189 If thinkfan tells you to, or if you feel like it, report issues at the
190 Github issue tracker:
191
192 https://github.com/vmatare/thinkfan/issues
193
194
195
196
197thinkfan 1.2 April 2020 THINKFAN(1)