Do you feel that your laptop is overheating abnormally under Ubuntu? This article proposes an approachsoftwarecomplete forcool, monitor et master the temperatureof your machine.

Objective of this guide

  • Reduce the overall temperature of the computer

  • Optimize energy management

  • Monitor critical components (CPU, GPU, etc.)

  • Avoid slowdowns due tothermal throttling

@startuml
start
:Installer les outils;
:Analyser les capteurs;
:Appliquer des réglages;
note right: cpufreq, tlp, auto-cpufreq
:Surveiller en temps réel;
stop
@enduml

Prerequisite

  • An Ubuntu machine (20.04 or higher recommended)

  • Internet connection

  • Command-line proficiency (beginner to intermediate)

Install and configure the tools

lm-sensors` to detect the sensors

sudo apt install lm-sensors
sudo sensors-detect
sensors

Answer`YES`to all the questions of`sensors-detect`to detect the modules.

tlp` : intelligent energy manager

sudo apt install tlp tlp-rdw
sudo systemctl enable tlp
sudo systemctl start tlp
@startuml
(*) --> "Active TLP?"
if "Yes" then
  --> [yes] "Consumption reduction"
  --> "CPU frequency limitation"
else
  --> [no] "Startup TLP"
  --> "Automatic activation"
endif
-->(*)
@enduml

cpufrequtils` : limit CPU frequencies

sudo apt install cpufrequtils
cpufreq-info
sudo cpufreq-set -g powersave
  • powersave: limits frequency peaks

  • `performance`favors power at the expense of temperature

auto-cpufreq` : simplified dynamic management

git clone https://github.com/AdnanHodzic/auto-cpufreq.git
cd auto-cpufreq
sudo ./auto-cpufreq-installer
sudo auto-cpufreq --install
@startuml
start
:Analyse charge système;
:Réglage fréquence CPU;
:Vérification température;
:Adaptation dynamique;
stop
@enduml

thermald` : automatic thermal protection

sudo apt install thermald
sudo systemctl enable thermald
sudo systemctl start thermald

Real-time monitoring

sensors` on the command line

watch -n 2 sensors

GUI option: `psensor

sudo apt install psensor

Simple graphical interface for CPU, GPU, fans.

Additional tips

  • Close heavy tabs and applications (e.g., browsers)

  • Avoid intensive usage on battery

  • Monitor the processes via`htop`:

sudo apt install htop
htop

Clean the system to limit overloads

sudo apt autoremove
sudo apt autoclean
sudo journalctl --vacuum-time=3d

To go further

You can create a service`systemd`customized to automatically apply some settings at startup. Would you like an example in a future article? Let me know!

Conclusion

By combining these simple tools, you will gain:

  • A controlled CPU temperature

  • Less ventilation noise

  • Better autonomy

Don’t forget to monitor your temperatures regularly to prevent any overheating.

__ Better to prevent than to melt your CPU. </think>

Related articles