Since quite a long I’m issuing issues with my fan rotation controlling software on Linux.
That is really annoying since every now and then I experience problems with overheats when my systemis under heavy loads.
That would interrupt my proper work with my notebook every now and then and had became a real pain in the asswith time.
I spend a lot time looking for a solution in the meantime trying all kind of scripts which mentioned on thinkwiki.org
I’ve had an unpleasent experiences with tpfand , tp-fancontrol as well as with the automated process to control fan through some kernel module options like:
options thinkpad_acpi fan_control=1
To solve my overheating issues when the temperature shown by lm-sensors was reaching 60 degrees andabove I had to manually change the fan rotation level with the command :
# increase thinkpad fan speed to max
root@noah:~# echo level 7 > /proc/acpi/ibm/fan
The manual way to increase fan rotation when my CPU was under a high load caused by the automated thinkpad_acpi kernel module wrongly controlling the fan speed was really irritating, therefore I looked for something online to manage the fan rotation to cool my cpu in a proper way, after the many failed attems to use some of the forementioned softwares as well as other techniques I found to be explained as a workarounds to tune the automated fan rotation speed.
I finally found Thinkfan . The wonderful guys from Debian has even prepared a packaged deb package of thinkfan, so as a debian user the whole thinkfan installation was as easy as:
root@noah:~# apt-get install thinkfan
Though thinkfan worked just fine most of the time and was able to control my fan speed automatically quite properly most of the time, it failed to do so every now and then.
Since failures to adjust properly the fan rotation speed on my Debian Linux when the system was under a stress was rare, I was quite happy with thinkfan as a fan manager for my desktop linux system most of the time.
The most often cases in which thinkfan failed to properly adjust my fan speed to cool my cpu properly was after system sleeps or hibernate
To work around this issue I have created a crontab which would periodically restart the thinkfan daemon, the crontab I used is as follows:
# restart thinkfan on every 30 minutes to prevent issues with thinkfan after hibernate and sleep on Debian Linux
0,30 * * * * /etc/init.d/thinkfan restart >/dev/null 2>&1
This kind of solution worked until recently when I have used apt-get to upgrade my system software to the latest versions, ever since then thinkfan misbehaving unabling to properly control my notebook lenovo thinkpad r61 fan speed.
The failure to control properly the fan speed was accompanied by the following thinkfan warning messages in /var/log/messages :
Jun 7 15:30:02 noah thinkfan: WARNING: Using default temperature inputs in /proc/acpi/ibm/thermal.
Jun 7 15:30:02 noah thinkfan: WARNING: You have not provided any correction values for any sensor, and your fan will only start at 55 °C. This can be dangerous for your hard drive.
I spend almost two hours Googling for the error and possible articles on how to configure my thinkfan /etc/thinkfan.conf to match my thinkpad r61 fan control but I couldn’t find anything meaningful in Google.
Thus I started experimenting changing values in my /etc/thinkfan.conf until I reached a moment the fan is properly controlled by thinkfan.
I thought this values could be of a great benefit to other Thinkpad R61 Linux users I decided to blog about my issues and my solution to fan control issues.
So if you are also in the same struggles with properly configuring the fan speed for thinkfan to match Thinkpad model R61, you will have to download my thinkpad r61 Correction values thinkfan.conf file
Our you can either just copy paste the following in your /etc/thinkfan.conf configuration file on your system:
(0, 38, 40)
(1, 42, 44)
(2, 46, 48)
(3, 50, 52)
(4, 54, 56)
(5, 58, 60)
(6, 62, 64)
(7, 66, 32767)
For other Lenovo / IBM Thinkpad model types the correction values might be close or even it’s possible that the same configuration to control your fan with thinkfan might be compatible with other Thinkpads.
If you test it on another thinkpad and you find it working or some tweakenings to the up-mentioned correction values help in tuning thinkfan on other Thinkpads, please post here!
Thanks God, now after simply restarting my thinkfan, my notebook fan is automatically properly set to rotate!
More helpful Articles
Tags: How to properly control your Lenovo Thinkpad R61 fan rotation cycles on Linux with ThinkFan
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.12) Gecko/20100911 Iceweasel/3.5.12 (like Firefox/3.5.12)
I wonder whether you could give more detailed explanation how to properly add crontab for thinkfan? Moreover, do we need it if we addjust /etc/thinkfan.conf?
Thanks!
View CommentView CommentPM
Mozilla/5.0 (X11; U; Linux x86_64; en-us) AppleWebKit/531.2+ (KHTML, like Gecko) Version/5.0 Safari/531.2+ Debian/squeeze (2.30.6-1) Epiphany/2.30.6
Hi having the crontab is not absolutely necessery, however it works well for me that’s why I mentioned it.
To add crontab type in your terminal for instance “crontab -u root -e”. Then you will have to deal with saving it after you paste what I point in the article should go in the crontab. Here it depends on your text editor if it’s vim or nano. If you’re with vi/vim you need to press “i” when the editor opens and laters press “esc” then “:x!” this will save the crontab and install it. If you’re with nano just place the crontab just like it’s said in the article and press “ctrl+x” this will save the edit.
Regards,
View CommentView CommentGeorgi
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.12) Gecko/20100911 Iceweasel/3.5.12 (like Firefox/3.5.12)
Thanks, very much!
Actually, I was wondering about the line in crontab, since they differ:
– above, line is: “0,30 * * * * /etc/init.d/thinkfan restart >/dev/null 2>&1”
– but in https://www.pc-freak.net/blog/controlling-fan-with-thinkfan-on-lenovo-thinkpad-r61-on-debian-gnulinux-adjusting-proper-fan-cycling/ (response link), line differs: “0,30 * * * * killall -HUP thinkfan”
That is why I am in doubt.
Thanks again!
View CommentView CommentPM
Mozilla/5.0 (X11; U; Linux x86_64; en-us) AppleWebKit/531.2+ (KHTML, like Gecko) Version/5.0 Safari/531.2+ Debian/squeeze (2.30.6-1) Epiphany/2.30.6
Well yes they do because, in newer version of thinkfan the package misses the /etc/init.d/thinkfan script.
Thus in newer versions where the scripts is not there just add the killall -HUP thinkfan rule in your crontab.
Best!
View CommentView CommentGeorgi
Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.1.3) Gecko/20090824 Firefox/3.5.3 (.NET CLR 3.5.30729)
Hello! I’ve read some of your publish right here and uncovered it fascinating and it makes a whole lot of sense. Plus i love your theme below. Thumbs up! Maintain on sharing!
View CommentView CommentMozilla/5.0 (X11; Linux i686; rv:6.0a1) Gecko/20110522 Firefox/6.0a1
Well I’m sorry, but the values listed there don’t seem to work with the latest thinkfan, for the LOWER limits don’t overlap with the previous UPPER limits.
I believe some easy adjustments will work.
Cheers!
View CommentView CommentMozilla/5.0 (X11; U; Linux x86_64; en-us) AppleWebKit/531.2+ (KHTML, like Gecko) Version/5.0 Safari/531.2+ Debian/squeeze (2.30.6-1) Epiphany/2.30.6
if you have values that work and you can post info about your exact linux version it will be great.
View CommentView CommentHope it might benefit others.
Mozilla/5.0 (X11; Linux i686; rv:7.0a1) Gecko/20110525 Firefox/7.0a1
just like this: (/etc/thinkfan.conf)
(0, 38, 42)
(1, 40, 46)
(2, 44, 50)
(3, 48, 54)
(4, 52, 58)
(5, 56, 62)
(6, 60, 66)
(7, 64, 32767)
I’m using Arch Linux, kernel 2.6.39, i686 Intel Pentium Dual, ThinkPad R61i.
View CommentView CommentMozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.1 (KHTML, like Gecko) Ubuntu/10.04 Chromium/14.0.811.0 Chrome/14.0.811.0 Safari/535.1
Zdrasti Georgi,
I have a question concerning the auto-start of the thinkfan daemon. The line “0,30 * * * * killall -HUP thinkfan†restarts the thinkfan every 30 minutes, but it does not start it when I boot the machine. Do you have a suggestion how thinkfan can be started automatically through crontab as well?
Cheers for the posts,
View CommentView CommentNikolay
Mozilla/5.0 (X11; U; Linux x86_64; en-us) AppleWebKit/531.2+ (KHTML, like Gecko) Version/5.0 Safari/531.2+ Debian/squeeze (2.30.6-1) Epiphany/2.30.6
ЗдраÑти Nikolay,
You can configure /etc/init.d/thinkfan to start up.
Or if you’re missing the thinkfan script I can put a link here for you.
Поздрав! 🙂
View CommentView CommentMozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.1 (KHTML, like Gecko) Ubuntu/10.04 Chromium/14.0.813.0 Chrome/14.0.813.0 Safari/535.1
ЗдраÑти и thanks for the fast reply,
I made a thinkfan_auto script which looks like this:
#!/bin/bash
sleep 30 && thinkfan ;
Then I copied it it /etc/init.d/ and run sudo update-rc.d thinkfan_auto defaults. But the program still doesn’t start at boot.
Any suggestion on how the script should look like is welcomed.
БлагодарÑ!
View CommentView CommentÐиколай
Mozilla/5.0 (X11; U; Linux x86_64; en-us) AppleWebKit/531.2+ (KHTML, like Gecko) Version/5.0 Safari/531.2+ Debian/squeeze (2.30.6-1) Epiphany/2.30.6
ЗдраÑти и ur welcome 🙂
You can download the script I use from below link.
http://www.pc-freak.net/files/thinkfan
Add the script to be loaded in your runlelvel, the Debian standard desktop runlevel is 2.
hipo@noah:/etc/init.d$ /sbin/runlevel
N 2
Issue the commands to add them in runlevel 2.
# cd /etc/rc2.d/; ln -sf /etc/init.d/thinkfan S19thinkfan
To be honest I never get used to update-rc.d 😉
If I can further help it will be a pleasure.
Ð’Ñичко най!
View CommentView CommentГеорги
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.1 (KHTML, like Gecko) Ubuntu/10.04 Chromium/14.0.813.0 Chrome/14.0.813.0 Safari/535.1
Thanks for the reply Georgi,
somehow I managed to get it working yesterday. I found the script you posted, and then enabled thinkfan in /etc/default/thinkfan (as said in the script). As I put the program thinkfan (the binary file) in /usr/local/sbin, I had to change the path in the script from DAEMON=/usr/sbin/$NAME to DAEMON=/usr/local/sbin/$NAME. At the end I run sudo update-rc.d -f thinkfan start 99 2 3 4 5 . and it worked 🙂
I don’t get why the scripts in /etc/init.d can not be a simple one line code (like in my previous post). Is that a security reason, or there is something deeper that I can’t understand?
Ð‘Ð»Ð°Ð³Ð¾Ð´Ð°Ñ€Ñ Ð·Ð° помощта!
View CommentView CommentÐŸÐ¾Ð·Ð´Ñ€Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð¸Ð· блога ти, доÑта интереÑни Ñтатии имаш. Ðай-вероÑтно ще Ñе видим пак по коментарите под Ñ‚ÑÑ… 😉
Поздрави, Ðиколай
Mozilla/5.0 (X11; U; Linux x86_64; en-us) AppleWebKit/531.2+ (KHTML, like Gecko) Version/5.0 Safari/531.2+ Debian/squeeze (2.30.6-1) Epiphany/2.30.6
Ur welcome 😉
Glad you make it. The reason behind the scripts are not just few lines is that if there are just few lines is versatile, it needs to make different checks related to the service activity up/down restart/stop/start options for the service etc.
ÐÑма проблем за помощта, радвам Ñе че Ñъм помогнал и че Ñ Ð½ÐµÑ‰Ð¾ ти е бил полезен блога.
Ще Ñе виждаме из коментарите.
Ð’Ñичко най!
View CommentView CommentГеорги
Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; GTB7.1; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.3; MS-RTC LM 8)
Is there a way to do this for idiots
View CommentView CommentMozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.17) Gecko/20110422 Ubuntu/8.04 (hardy) Firefox/3.6.17
Do that for idiots? 🙂 I think I know what you mean. But I don’t know by so far for another way
View CommentView CommentMozilla/5.0 (X11; U; Linux i686; it-IT; rv:1.9.0.2) Gecko/2008092313 Ubuntu/9.25 (jaunty) Firefox/3.8
É pá! É que nao quero que te falte nada!!!
View CommentView CommentMozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.17 (KHTML, like Gecko) Chrome/24.0.1312.68 Safari/537.17
Your blog sucks, hard.
http://sourceforge.net/p/thinkfan/discussion/905019/thread/24c3cd47
View CommentView Comment