ThinkPad Fan Control: Unterschied zwischen den Versionen

Aus ThinkPad-Wiki
(→‎Voraussetzungen: Anleitung funktioniert auch unter Natty, das fehlte noch in der Liste)
Keine Bearbeitungszusammenfassung
 
(36 dazwischenliegende Versionen von 6 Benutzern werden nicht angezeigt)
Zeile 1: Zeile 1:
== Einleitung ==
= Einleitung =
[http://www.gambitchess.org/mediawiki/index.php/ThinkPad_Fan_Control Thinkpad Fan Control] ist eine Software zur Lüftersteuerung für Linux. Im Unterschied zu [[Thinkfan]] beinhaltet Thinkpad Fan Control eine GUI zur Einstellung der Temperaturschwellen.
[[Bild:Tpfan-admin.png|GUI von Thinkpad Fan Control|thumb]]
ThinkPad Fan Control (auch als tp-fan oder tpfand bekannt) ist eine Software zur Lüftersteuerung für Linux. Im Unterschied zu [[Thinkfan]] beinhaltet ThinkPad Fan Control eine GUI zur Einstellung der Temperaturschwellen. Leider wird das ursprüngliche tp-fan von seinem Autor seit Mitte 2009 nicht mehr gewartet.  


== Voraussetzungen ==
Seit September 2011 gibt es ein neues Projekt namens [http://code.google.com/p/tpfanco/ tpfanco], das sich um die Wartung des Codes von tp-fan und die Erstellung von aktuellen Ubuntu-Paketen kümmert.
Da die Weiterentwicklung von Thinkpad Fan Control schon vor einiger Zeit eingestellt wurde, finden sich im [https://launchpad.net/~tp-fan/+archive/ppa PPA] nur Pakete bis einschließlich Ubuntu 9.04. Dieser Artikel beschreibt Installation und Konfiguration der vorhandenen Pakete unter:
* Ubuntu 10.04 "Lucid Lynx"
* Ubuntu 10.10 "Maverick Meerkat"
* Ubuntu 11.04 "Natty Narwahl"


Unterstützt werden alle ThinkPad-Modelle bei denen das Kernelmodul '''thinkpad_acpi''' geladen werden kann. Ausnahmen sind:
= Voraussetzungen =
* SL-Reihe: keine Unterstützung für thinkpad_acpi
Nicht unterstützt werden folgende ThinkPad-Modelle:
* L-, Edge-Reihe, X100e: benötigt Ubuntu 10.10 mit Kernel 2.6.35 oder 10.04 mit [[Ubuntu_tp-Kernel|tp-Kernel 2.6.32]]
* SL300/400/500-Reihe: keine Unterstützung für thinkpad_acpi
* Edge E330/E530: '''/proc/acpi/ibm/fan''' ohne Funktion
* T420(s)/T520/W520/X220 und neuer Modelle: keine Unterstützung für '''/proc/acpi/ibm/thermal''' – siehe eigenen Abschnitt am Ende


== Installation ==
= Installation =
=== Ubuntu 10.04 ===
Man lädt die drei für 9.04 bestimmten Pakete von Hand aus dem [https://launchpad.net/~tp-fan/+archive/ppa PPA] herunter und installiert sie:
* '''[http://ppa.launchpad.net/tp-fan/ppa/ubuntu/pool/main/t/tpfand/tpfand_0.95-ubuntu1_all.deb tpfand]'''
* '''[http://ppa.launchpad.net/tp-fan/ppa/ubuntu/pool/main/t/tpfan-admin/tpfan-admin_0.96-ubuntu1_all.deb tpfan-admin]'''
* '''[http://ppa.launchpad.net/tp-fan/ppa/ubuntu/pool/main/t/tpfand-profiles/tpfand-profiles_20090309-ubuntu1_all.deb tpfand-profiles]'''


=== Ubuntu 10.10 ===
== Ubuntu ==
Um ThinkPad Fan Control unter Ubuntu 10.10 zu nutzen, müssen die vorhandenen Pakete entsprechend angepasst werden. Dafür gibt es zwei Gründe:
'''<u>Hinweis:</u> Das PPA wird derzeit nicht gewartet. Ggf. muß man die Anwendung aus dem Sourecode bauen und installieren – siehe [[Thinkpad_Fan_Control#Links|Links]].'''
* zur Bestimmung des Thinkpad-Modells verwendet tpfan die ab Ubuntu 10.10 nicht mehr vorhandene HAL-Schnittstelle
* tpfan-admin hängt vom Paket python-gnome2-desktop, welches ab Ubuntu 10.10 ebenfalls nicht mehr vorhanden ist
Für diese Probleme gibt es folgende Lösungen
* ein [https://bugs.launchpad.net/tp-fan/+bug/575199/comments/3 Patch] für tpfan sorgt dafür, dass die Modellbestimmung über lshw funktioniert
* python-gnome2-desktop-Abhängigkeit von tpfan-admin muss durch python-rsvg ersetzt werden
All das lässt sich vollautomatisch erledigen. Zuerst installiert man das Paket '''patch''':
sudo apt-get install patch
Anschließend öffnet man die Kommandozeile und gibt folgende Befehle ein
cd ~
echo "Patching tpfan-admin"
wget http://ppa.launchpad.net/tp-fan/ppa/ubuntu/pool/main/t/tpfan-admin/tpfan-admin_0.96-ubuntu1_all.deb
dpkg-deb -x tpfan-admin_0.96-ubuntu1_all.deb tpfan-admin_0.96-ubuntu1_all_patched
dpkg-deb -e tpfan-admin_0.96-ubuntu1_all.deb tpfan-admin_0.96-ubuntu1_all_patched/DEBIAN
sed -i 's/python-gnome2-desktop (>= 2.22)/python-rsvg (>=2.30.0)/g' tpfan-admin_0.96-ubuntu1_all_patched/DEBIAN/control
dpkg-deb -b tpfan-admin_0.96-ubuntu1_all_patched
rm -r tpfan-admin_0.96-ubuntu1_all_patched tpfan-admin_0.96-ubuntu1_all.deb
echo "Patching tpfand"
wget http://ppa.launchpad.net/tp-fan/ppa/ubuntu/pool/main/t/tpfand/tpfand_0.95-ubuntu1_all.deb
dpkg-deb -x tpfand_0.95-ubuntu1_all.deb tpfand_0.95-ubuntu1_all_patched
dpkg-deb -e tpfand_0.95-ubuntu1_all.deb tpfand_0.95-ubuntu1_all_patched/DEBIAN
wget https://bugs.launchpad.net/tp-fan/+bug/575199/+attachment/1702159/+files/tpfan_nohal.patch
patch tpfand_0.95-ubuntu1_all_patched/usr/share/pyshared/tpfand/settings.py -i tpfan_nohal.patch -o tpfand_0.95-ubuntu1_all_patched/usr/share/pyshared/tpfand/settings_patch.py
mv tpfand_0.95-ubuntu1_all_patched/usr/share/pyshared/tpfand/settings_patch.py tpfand_0.95-ubuntu1_all_patched/usr/share/pyshared/tpfand/settings.py
dpkg-deb -b tpfand_0.95-ubuntu1_all_patched
rm -r tpfand_0.95-ubuntu1_all.deb tpfan_nohal.patch tpfand_0.95-ubuntu1_all_patched
wget http://ppa.launchpad.net/tp-fan/ppa/ubuntu/pool/main/t/tpfand-profiles/tpfand-profiles_20090309-ubuntu1_all.deb
Die Warnungen seitens dpkg-deb können ignoriert werden. Anschließend findet man in seinem Home-Verzeichnis folgende Dateien:
tpfand_0.95-ubuntu1_all_patched.deb
tpfan-admin_0.96-ubuntu1_all_patched.deb
tpfand-profiles_20090309-ubuntu1_all.deb
Diese sollen in genau dieser Reihenfolge durch Doppelklicken installiert werden. Danach am besten den Rechner neustarten, damit die vorhandenen Profile
verwendet werden können. Nach dem Neustart ruft man die Konfiguration mit ''"System -> Systemeinstellungen -> ThinkPad Fan Control"'' auf.


=== Kubuntu 10.10 ===
Für Ubuntu 12.04 und 14.04 (auch Kubuntu, Xubuntu, Mint etc.) steht ein [https://launchpad.net/~vl-sht/+archive/tpfanco PPA] zur Verfügung, das man wie folgt als Paketquelle einrichtet:
Um ThinkPad Fan Control unter Kubuntu 10.10 zu nutzen, müssen die vorhandenen Pakete entsprechend angepasst werden. Dafür gibt es drei Gründe:
* zur Bestimmung des Thinkpad-Modells verwendet tpfan die ab Ubuntu 10.10 nicht mehr vorhandene HAL-Schnittstelle
* tpfan-admin hängt vom Paket python-gnome2-desktop, welches ab Ubuntu 10.10 ebenfalls nicht mehr vorhanden ist
* um root-Rechte zu erlangen, setzt tpfan-admin auf gksu, was unter KDE nicht wirklich reibungslos funktioniert
Für diese Probleme gibt es folgende Lösungen
* ein [https://bugs.launchpad.net/tp-fan/+bug/575199/comments/3 Patch] für tpfan sorgt dafür, dass die Modellbestimmung über lshw funktioniert
* python-gnome2-desktop-Abhängigkeit von tpfan-admin muss durch python-rsvg ersetzt werden
* gksu-Aufrufe im Quellcode müssen durch kdesudo ersetzt werden.
All das lässt sich vollautomatisch erledigen. Zuerst installiert man das Paket '''patch''':
sudo apt-get install patch
Anschließend öffnet man die Kommandozeile und gibt folgende Befehle ein
cd ~
echo "Patching tpfan-admin for Kubuntu"
wget http://ppa.launchpad.net/tp-fan/ppa/ubuntu/pool/main/t/tpfan-admin/tpfan-admin_0.96-ubuntu1_all.deb
dpkg-deb -x tpfan-admin_0.96-ubuntu1_all.deb tpfan-admin_0.96-ubuntu1_all_patched_KDE
dpkg-deb -e tpfan-admin_0.96-ubuntu1_all.deb tpfan-admin_0.96-ubuntu1_all_patched_KDE/DEBIAN
sed -i 's/python-gnome2-desktop (>= 2.22)/python-rsvg (>=2.30.0)/g' tpfan-admin_0.96-ubuntu1_all_patched_KDE/DEBIAN/control
sed -i 's/gksu (>= 2.0)/kdesudo (>= 2.5)/g' tpfan-admin_0.96-ubuntu1_all_patched_KDE/DEBIAN/control
sed -i 's/gksu/kdesudo/;s/--message/--comment/g' tpfan-admin_0.96-ubuntu1_all_patched_KDE/usr/share/pyshared/tpfanadmin/build.py
dpkg-deb -b tpfan-admin_0.96-ubuntu1_all_patched_KDE
rm -r tpfan-admin_0.96-ubuntu1_all_patched_KDE tpfan-admin_0.96-ubuntu1_all.deb
echo "Patching tpfand for Kubuntu"
wget http://ppa.launchpad.net/tp-fan/ppa/ubuntu/pool/main/t/tpfand/tpfand_0.95-ubuntu1_all.deb
dpkg-deb -x tpfand_0.95-ubuntu1_all.deb tpfand_0.95-ubuntu1_all_patched_KDE
dpkg-deb -e tpfand_0.95-ubuntu1_all.deb tpfand_0.95-ubuntu1_all_patched_KDE/DEBIAN
wget https://bugs.launchpad.net/tp-fan/+bug/575199/+attachment/1702159/+files/tpfan_nohal.patch
patch tpfand_0.95-ubuntu1_all_patched_KDE/usr/share/pyshared/tpfand/settings.py -i tpfan_nohal.patch -o tpfand_0.95-ubuntu1_all_patched_KDE/usr/share/pyshared/tpfand/settings_patch.py
mv tpfand_0.95-ubuntu1_all_patched_KDE/usr/share/pyshared/tpfand/settings_patch.py tpfand_0.95-ubuntu1_all_patched_KDE/usr/share/pyshared/tpfand/settings.py
dpkg-deb -b tpfand_0.95-ubuntu1_all_patched_KDE
rm -r tpfand_0.95-ubuntu1_all.deb tpfan_nohal.patch tpfand_0.95-ubuntu1_all_patched_KDE
wget http://ppa.launchpad.net/tp-fan/ppa/ubuntu/pool/main/t/tpfand-profiles/tpfand-profiles_20090309-ubuntu1_all.deb
Die Warnungen seitens dpkg-deb können ignoriert werden. Anschließend findet man in seinem Home-Verzeichnis folgende Dateien:  
tpfand_0.95-ubuntu1_all_patched_KDE.deb
tpfan-admin_0.96-ubuntu1_all_patched_KDE.deb
tpfand-profiles_20090309-ubuntu1_all.deb
Diese sollen in genau dieser Reihenfolge durch Doppelklicken installiert werden. Danach am besten den Rechner neustarten, damit die vorhandenen Profile
verwendet werden können. Nach dem Neustart ruft man die Konfiguration mit ''"KDE -> Anwendungen -> System -> ThinkPad Fan Control"'' auf.


=== Ubuntu 11.04 ===
sudo add-apt-repository ppa:vl-sht/tpfanco
Um ThinkPad Fan Control unter Ubuntu 11.04 zu nutzen, müssen die vorhandenen Pakete entsprechend angepasst werden. Dafür gibt es einige Gründe:
  sudo apt-get update
* zur Bestimmung des Thinkpad-Modells verwendet tpfan die ab Ubuntu 11.04 nicht mehr vorhandene HAL-Schnittstelle
* tpfan-admin hängt vom Paket python-gnome2-desktop, welches ab Ubuntu 11.04 ebenfalls nicht mehr vorhanden ist
Für diese Probleme gibt es folgende Lösungen
* ein [https://bugs.launchpad.net/tp-fan/+bug/575199/comments/4 Patch] für tpfan sorgt dafür, dass die Modellbestimmung über dmidecode
* python-gnome2-desktop-Abhängigkeit von tpfan-admin muss durch python-rsvg ersetzt werden
All das lässt sich vollautomatisch erledigen. Zuerst installiert man das Paket '''patch''':
  sudo apt-get install patch
Anschließend öffnet man die Kommandozeile und gibt folgende Befehle ein
cd ~
# Patching tpfan-admin
wget http://ppa.launchpad.net/tp-fan/ppa/ubuntu/pool/main/t/tpfan-admin/tpfan-admin_0.96-ubuntu1_all.deb
dpkg-deb -x tpfan-admin_0.96-ubuntu1_all.deb tpfan-admin_0.96-ubuntu1_all_patched
dpkg-deb -e tpfan-admin_0.96-ubuntu1_all.deb tpfan-admin_0.96-ubuntu1_all_patched/DEBIAN
sed -i 's/python-gnome2-desktop (>= 2.22)/python-rsvg (>=2.30.0)/g' tpfan-admin_0.96-ubuntu1_all_patched/DEBIAN/control
# This is needed to make our package pass the lintian-check
sed -i 's/# Please also look if there are files or directories which have a//g' tpfan-admin_0.96-ubuntu1_all_patched/usr/share/doc/tpfan- admin/copyright
sed -i 's/# different copyright\/license attached and list them here.//g' tpfan-admin_0.96-ubuntu1_all_patched/usr/share/doc/tpfan-admin/copyright
chmod +x tpfan-admin_0.96-ubuntu1_all_patched/usr/share/tpfan-admin/open-url.sh
cd tpfan-admin_0.96-ubuntu1_all_patched
find usr/ -type f -print0 | xargs -0 md5sum > DEBIAN/md5sums
cd ~
# Building the package
fakeroot dpkg-deb -b tpfan-admin_0.96-ubuntu1_all_patched
rm -r tpfan-admin_0.96-ubuntu1_all_patched tpfan-admin_0.96-ubuntu1_all.deb
# Patching tpfand
wget http://ppa.launchpad.net/tp-fan/ppa/ubuntu/pool/main/t/tpfand/tpfand_0.95-ubuntu1_all.deb
dpkg-deb -x tpfand_0.95-ubuntu1_all.deb tpfand_0.95-ubuntu1_all_patched
dpkg-deb -e tpfand_0.95-ubuntu1_all.deb tpfand_0.95-ubuntu1_all_patched/DEBIAN
cd tpfand_0.95-ubuntu1_all_patched/usr/share/pyshared/
wget https://launchpadlibrarian.net/70852691/tpfan_dmidecode.patch
patch -p0 < tpfan_dmidecode.patch
rm tpfan_dmidecode.patch
cd ~
sed -i 's/python-dbus (>= 0.82)/python-dbus (>= 0.82), python-dmidecode (>= 3.10)/g' tpfand_0.95-ubuntu1_all_patched/DEBIAN/control
# This is needed to make our package pass the lintian-check
cd tpfand_0.95-ubuntu1_all_patched
find usr/ -type f -print0 | xargs -0 md5sum > DEBIAN/md5sums
cd ~
sed -i 's/Required-Start:    $syslog $time/Required-Start:    $remote_fs $syslog $time/g' tpfand_0.95-ubuntu1_all_patched/etc/init.d/tpfand
sed -i 's/Required-Stop:    $syslog $time/Required-Stop:    $remote_fs $syslog $time/g' tpfand_0.95-ubuntu1_all_patched/etc/init.d/tpfand
sed -i 's/*)/force-reload)\n        $0 restart\n        ;;\n&\n /g' tpfand_0.95-ubuntu1_all_patched/etc/init.d/tpfand
sed -i 's/restart}/restart|force-reload}/g' tpfand_0.95-ubuntu1_all_patched/etc/init.d/tpfand
# Building the package
fakeroot dpkg-deb -b tpfand_0.95-ubuntu1_all_patched
rm -r tpfand_0.95-ubuntu1_all.deb tpfand_0.95-ubuntu1_all_patched
wget http://ppa.launchpad.net/tp-fan/ppa/ubuntu/pool/main/t/tpfand-profiles/tpfand-profiles_20090309-ubuntu1_all.deb
Die Warnungen seitens dpkg-deb können ignoriert werden. Anschließend findet man in seinem Home-Verzeichnis folgende Dateien:
tpfand_0.95-ubuntu1_all_patched.deb
tpfan-admin_0.96-ubuntu1_all_patched.deb
tpfand-profiles_20090309-ubuntu1_all.deb
Diese sollen in genau dieser Reihenfolge durch Doppelklicken installiert werden. Danach am besten den Rechner neustarten, damit die vorhandenen Profile
verwendet werden können. Nach dem Neustart ruft man die Konfiguration mit ''"System -> Systemeinstellungen -> ThinkPad Fan Control"'' auf.


== Konfiguration ==
Die benötigten Pakete
Nach der Installation ruft man die Konfiguration mit ''"System -> Systemeinstellungen -> ThinkPad Fan Control"'' auf.
* '''tpfand'''
* '''tpfan-admin'''
* '''tpfand-profiles'''
installiert man entweder per [http://wiki.ubuntuusers.de/Paketverwaltung#Paketverwaltung Paketverwaltung] oder im Terminal mit:
sudo apt-get install tpfand tpfan-admin tpfand-profiles
 
<u>Wichtig:</u> Nach der Installation ist ein Neustart erforderlich.
 
Nach dem Neustart kann die Konfiguration (tpfan-admin) im [http://wiki.ubuntuusers.de/Unity/Unity_Startmen%C3%BC#Schnellstart Schnellstart] mit dem Stichwort "tpfan" aufgerufen werden.
 
= T420(s)/T520/W520/X220 und neuere Modelle – nur für Fortgeschrittene! =
Das Problem der Sandy-Bridge- und neuerer ThinkPad-Generationen lässt sich durch manuelle Anpassung des Codes lösen:
[http://thinkpad-forum.de/threads/121896-Projektvorstellung-Tpfanco-Wartung-und-Paketierung-von-tp-fan?p=1468596&viewfull=1#post1468596 Thread im Forum]. Evtl. wird daraus noch eine automatische Erkennung werden.
 
= Links =
* [https://github.com/tpfanco tpfanco-Sourcecode bei GitHub]
* [http://thinkpad-forum.de/threads/121896-Projektvorstellung-Tpfanco-Wartung-und-Paketierung-von-tp-fan tpfanco-Thread im  Thinkpad-Forum]
 
[[Category:Linux]]
[[Category:Ubuntu]]
[[Category:Lüftersteuerung]]

Aktuelle Version vom 2. Januar 2016, 23:09 Uhr

Einleitung

GUI von Thinkpad Fan Control

ThinkPad Fan Control (auch als tp-fan oder tpfand bekannt) ist eine Software zur Lüftersteuerung für Linux. Im Unterschied zu Thinkfan beinhaltet ThinkPad Fan Control eine GUI zur Einstellung der Temperaturschwellen. Leider wird das ursprüngliche tp-fan von seinem Autor seit Mitte 2009 nicht mehr gewartet.

Seit September 2011 gibt es ein neues Projekt namens tpfanco, das sich um die Wartung des Codes von tp-fan und die Erstellung von aktuellen Ubuntu-Paketen kümmert.

Voraussetzungen

Nicht unterstützt werden folgende ThinkPad-Modelle:

  • SL300/400/500-Reihe: keine Unterstützung für thinkpad_acpi
  • Edge E330/E530: /proc/acpi/ibm/fan ohne Funktion
  • T420(s)/T520/W520/X220 und neuer Modelle: keine Unterstützung für /proc/acpi/ibm/thermal – siehe eigenen Abschnitt am Ende

Installation

Ubuntu

Hinweis: Das PPA wird derzeit nicht gewartet. Ggf. muß man die Anwendung aus dem Sourecode bauen und installieren – siehe Links.

Für Ubuntu 12.04 und 14.04 (auch Kubuntu, Xubuntu, Mint etc.) steht ein PPA zur Verfügung, das man wie folgt als Paketquelle einrichtet:

sudo add-apt-repository ppa:vl-sht/tpfanco 
sudo apt-get update

Die benötigten Pakete

  • tpfand
  • tpfan-admin
  • tpfand-profiles

installiert man entweder per Paketverwaltung oder im Terminal mit:

sudo apt-get install tpfand tpfan-admin tpfand-profiles

Wichtig: Nach der Installation ist ein Neustart erforderlich.

Nach dem Neustart kann die Konfiguration (tpfan-admin) im Schnellstart mit dem Stichwort "tpfan" aufgerufen werden.

T420(s)/T520/W520/X220 und neuere Modelle – nur für Fortgeschrittene!

Das Problem der Sandy-Bridge- und neuerer ThinkPad-Generationen lässt sich durch manuelle Anpassung des Codes lösen: Thread im Forum. Evtl. wird daraus noch eine automatische Erkennung werden.

Links