How to Monitor Hardware Temperature and Usage on a Raspberry Pi

The Boss

PC

How to Monitor Hardware Temperature and Usage on a Raspberry Pi

Hardware, monitor, Raspberry, temperature, usage

In the first models of Raspberry Pitemperature monitoring was not something very important, because with the low power of its SoC, almost nothing heated up. However, with the arrival of the Raspberry Pi 5, this has changed, as it is now necessary to use a heat sink to keep the heat at bay. temperature. And, if you want to be able to monitor it, in this article we will explain how to do it in a simple and fairly quick way.

There are actually many ways to monitor temperature on a Raspberry Pi, but many of them involve installing and configuring an additional physical external module. Fortunately, this is also something that can be done by software, and in this case we are going to use the free tool Cockpitwhich in addition to allowing us to see the temperature and resource consumption of the device, serves many other purposes.

How to install Cockpit on a Raspberry Pi

Cockpit is an extremely powerful and useful tool for managing a Raspberry Pi without having to physically access the device, which is normal for most users who really want the Raspberry to act as a server of some sort. The first time you will need to physically use the Raspberry Pi, or at least connect to it via SSH.

The first step is to ensure that the list of packages installed on the operating system is up to date, as well as the repository. To do this, you need to run two commands:

sudo apt update

sudo apt upgrade -y

Raspberry Pi update

In the case of the screenshot above, everything was already updated, but if this were not the case, with these commands we would update everything and we would be ready to install Cockpit. Enter the following command:

sudo apt install cockpit

Once finished, Cockpit will be installed and running on your Raspberry Pi, so you can now close SSH and log in to Cockpit from a web browser. To do this, you need to know the IP address of your Raspberry Pi (if you don't know it, before closing SSH, type the command hostname -I (be careful, it's a capital i) and it will appear).

The address you need to enter in the browser is https://XXXX:9090/system (change the Raspberry Pi. Once done, you will see the main Cockpit control panel, and there you will be able to see, under the box “Usage”, CPU and memory usage But we can see more data in the section just below that says “View metrics and history”.

Raspberry Pi Cockpit Menu

This section shows more data, such as usage of all cores separately, services consuming the most CPU, separate breakdown of RAM and Swap consumption, live data from storage, as well as network , wired and wireless. Come on, a fairly complete monitoring of the Raspberry Pi hardware (including the temperature, just above the CPU).

Raspberry Pi 5 data

In any case, installing Cockpit is not only for monitoring the hardware of the Raspberry Pi, but it can also help you update the software without having to enter commands, schedule services, create timers and a lot of extra stuff. Take a look, it's worth it.

Leave a Comment