Home Command line utilities How To View CPU Temperature On Linux
View CPU Temperature On Linux

How To View CPU Temperature On Linux

By sk

This brief tutorial describes how to view CPU temperature on Linux using lm_sensors. The Lm_sensors, short for Linux-monitoring sensors,  is a free software that provides the necessary tools and drivers for monitoring CPU temperatures, voltage, humidity, and fans. It can also detect chassis intrusions. So, you can find out a defective hardware components, and replace it to avoid the system hanging or overheating issues.

View CPU Temperature On Linux Using Lm_sensors


Lm_sensors comes pre-installed with most modern Linux operating systems. If it is not installed already, you can install it as shown below.

On Arch Linux and its derivatives:

$ sudo pacman -S lm_sensors

On RHEL, CentOS, Fedora:

$ sudo yum install lm_sensors


$ sudo dnf install lm_sensors

On Debian, Ubuntu, Linux Mint:

$ sudo apt-get install lm-sensors

On SUSE, openSUSE:

$ sudo zypper in sensors


Once installed, run the following command to configure lm_sensors:

$ sudo sensors-detect

The sensors-detect is a stand-alone program for detecting installed hardware and recommending specific modules to load. The "safe" answers are the defaults, so just hit to ENTER the accept the default values. It won't cause any problems. This will create the /etc/conf.d/lm_sensors configuration file which is used by lm_sensors.service to automatically load kernel modules on boot.

The sample output of the above command in my DELL Laptop:

# sensors-detect revision $Revision$
# System: Dell Inc. Inspiron N5050 [Not Specified] (laptop)
# Board: Dell Inc. 01HXXJ
# Kernel: 4.10.8-1-ARCH x86_64
# Processor: Intel(R) Core(TM) i3-2350M CPU @ 2.30GHz (6/42/7)

This program will help you determine which kernel modules you need
to load to use lm_sensors most effectively. It is generally safe
and recommended to accept the default answers to all questions,
unless you know what you're doing.

Some south bridges, CPUs or memory controllers contain embedded sensors.
Do you want to scan for them? This is totally safe. (YES/no): 
Module cpuid loaded successfully.
Silicon Integrated Systems SIS5595... No
VIA VT82C686 Integrated Sensors... No
VIA VT8231 Integrated Sensors... No
AMD K8 thermal sensors... No
AMD Family 10h thermal sensors... No
AMD Family 11h thermal sensors... No
AMD Family 12h and 14h thermal sensors... No
AMD Family 15h thermal sensors... No
AMD Family 16h thermal sensors... No
AMD Family 15h power sensors... No
AMD Family 16h power sensors... No
Intel digital thermal sensor... Success!
 (driver `coretemp')
Intel AMB FB-DIMM thermal sensor... No
Intel 5500/5520/X58 thermal sensor... No
VIA C7 thermal sensor... No
VIA Nano thermal sensor... No

Some Super I/O chips contain embedded sensors. We have to write to
standard I/O ports to probe them. This is usually safe.
Do you want to scan for Super I/O sensors? (YES/no): 
Probing for Super-I/O at 0x2e/0x2f
Trying family `National Semiconductor/ITE'... No
Trying family `SMSC'... No
Trying family `VIA/Winbond/Nuvoton/Fintek'... No
Trying family `ITE'... No
Probing for Super-I/O at 0x4e/0x4f
Trying family `National Semiconductor/ITE'... Yes
Found unknown chip with ID 0xfc11

Some hardware monitoring chips are accessible through the ISA I/O ports.
We have to write to arbitrary I/O ports to probe them. This is usually
safe though. Yes, you do have ISA I/O ports even if you do not have any
ISA slots! Do you want to scan the ISA I/O ports? (YES/no): 
Probing for `National Semiconductor LM78' at 0x290... No
Probing for `National Semiconductor LM79' at 0x290... No
Probing for `Winbond W83781D' at 0x290... No
Probing for `Winbond W83782D' at 0x290... No

Lastly, we can probe the I2C/SMBus adapters for connected hardware
monitoring devices. This is the most risky part, and while it works
reasonably well on most systems, it has been reported to cause trouble
on some systems.
Do you want to probe the I2C/SMBus adapters now? (YES/no): 
Using driver `i2c-i801' for device 0000:00:1f.3: Intel Cougar Point (PCH)
Module i2c-dev loaded successfully.

Next adapter: SMBus I801 adapter at f040 (i2c-0)
Do you want to scan it? (YES/no/selectively): 
Client found at address 0x50
Probing for `Analog Devices ADM1033'... No
Probing for `Analog Devices ADM1034'... No
Probing for `SPD EEPROM'... Yes
 (confidence 8, not a hardware monitoring chip)
Probing for `EDID EEPROM'... No

Next adapter: i915 gmbus ssc (i2c-1)
Do you want to scan it? (yes/NO/selectively): 

Next adapter: i915 gmbus vga (i2c-2)
Do you want to scan it? (yes/NO/selectively): 

Next adapter: i915 gmbus panel (i2c-3)
Do you want to scan it? (yes/NO/selectively): 

Next adapter: i915 gmbus dpc (i2c-4)
Do you want to scan it? (yes/NO/selectively): 

Next adapter: i915 gmbus dpb (i2c-5)
Do you want to scan it? (yes/NO/selectively): 

Next adapter: i915 gmbus dpd (i2c-6)
Do you want to scan it? (yes/NO/selectively): 

Next adapter: DPDDC-B (i2c-7)
Do you want to scan it? (yes/NO/selectively): 

Now follows a summary of the probes I have just done.
Just press ENTER to continue: 

Driver `coretemp':
 * Chip `Intel digital thermal sensor' (confidence: 9)

Do you want to overwrite /etc/conf.d/lm_sensors? (YES/no): 
Unloading i2c-dev... OK
Unloading cpuid... OK

Now, type the following command to view the CPU temperature information of your Linux box:

$ sensors

Sample output:

Adapter: ISA adapter
Package id 0: +65.0°C (high = +80.0°C, crit = +85.0°C)
Core 0: +65.0°C (high = +80.0°C, crit = +85.0°C)
Core 1: +63.0°C (high = +80.0°C, crit = +85.0°C)

Adapter: Virtual device
temp1: +63.5°C (crit = +84.0°C)

Adapter: Virtual device
Processor Fan: 4016 RPM
CPU: +63.0°C 
Other: +59.0°C 
Other: +57.0°C 
GPU: +16.0°C

As you see in the above output, lm_sensors displays my CPU's current temperature, high and critical temperature in the brackets. If you find out any of your hardware devices reaches high or critical temperature, you probably need to check that hardware device.

To display the temperatures in degrees Fahrenheit instead of Celsius, use -f option.

$ sensors -f

To monitor the CPU temperature in real time, you can use 'watch' command like below.

$ watch sensors

Sample output:

View CPU temperature On Linux In Real Time

View CPU temperature On Linux In Real Time

Press CTRL+C to stop the monitoring at any time.

For more details, refer the man pages.

$ man sensors

And, that's all. If you find this guide useful, please show your support by sharing it on your social and professional networks.



Thanks for stopping by!

Help us to help you:

Have a Good day!!

You May Also Like


Moltke September 18, 2017 - 9:55 pm

Hi! Nice blog. I used to use sensors command to check on cpu temps, however, I had to open the terminal every time to do that, so I found and installed an applet for the xfce panel, but again, is the same story with the terminal and sensors command. I’d like an utility that shows cpu temps in the panel without the need of opening anything. Is there such a way to show cpu temps on the xfce panel? So far I found nothing that works. I’m on Linux Lite XFCE flavour by the way. I’m not exactly new to Linux but I’m not expert neither. Thanks, and again great blog you have here! 🙂

Александр Костик January 11, 2018 - 12:05 am

thanks !

muondude September 9, 2018 - 10:51 pm

Thanks for the post. This works just as you show on Debian 9.5!

Josh Freeno October 10, 2018 - 8:50 pm

I am on Manjaro KDE and my machine is a Yoga laptop and I cant get the fan rpm to show up. I reinstalled lm_sensors but with the same result. My machine is not running hot but I need to be able to see fan speed. Also I am new to linux and really giving this a go and was seriously thinking of doing away with windows 10 all together but then I ran into this and before I delete windows I would like to make sure I have all the wrinkles out ya know. Your tutorials have been so much help to me. Thanks for the great work.

sk October 11, 2018 - 9:50 am

You’re welcome.

Jovan R. April 8, 2019 - 8:44 am

@Moltke : Did you find this XFCE plugin “xfce4-sensors-plugin” and installed it ? If you did, it should appear in the “Add New Items…” on the left mouse click anywhere on the panel and then select this item as “Sensor plugin” . Or, you can left click on the panel and select “Panel Preferences…” and then “Items” tab followed by click on big “+” -> where you can search for “sen” . After you add this to the panel, you have to put checkmark on the desired sensor. You may have added this plugin to the panel, but if you did not configured it to show your sensors values, it will be blank (panel background color) in the panel. To confugure it to show values, there is two ways. First, go to the panel preferences, select “Sensor plugin” and click on the gear icon. Second, find blank space in the panel with your mouse, do not move it for a while – there should be pop-up below mouse cursor with text “No sensors selected!”. When you put a checkmark on the desired sensors, they will be shown on the panel. When you are at this window, look at the other tabs/options. Here we can change the temparature units (Cels./Far.), rename (change) the text (labels) if double-clck ont the “Name” field, etc…

@Josh F. : Your Yoga laptop (maybe) is not well supported by the lm_sensors package or it’s configuration. Did you find your sensors chip in the output of sensors-detect command? If answer is yes, then you have to tweak lm_sensors configuration. It is in the “/etc/sensors3.conf” . There should be a “sensors.d” folder in the same place. I think that by default this “sen*.d” is empty. You can copy “sensors3.conf” to this folder, rename it (but, prepend [add] a number before the rest of the name) to match your laptop. This is because, files in this folder are alphanumeric looked up by the lm_sensors package. You should google search for the right settings for your laptop.
For that, I can’t help you.

@sk: Sorry for the lenghty post…

sk April 8, 2019 - 11:50 am

Thank you for your lengthy, yet descriptive and helpful comment, Jovan. Much appreciated.

J Park July 18, 2019 - 11:40 am

Thank you very much for your endeavor.

Mark December 8, 2019 - 10:49 pm

Nice guide! Very helpful, thanks.

vj March 3, 2020 - 12:56 pm

superb thanks

Jeff April 6, 2020 - 2:37 am

Thank you very much for writing this article – it is most informative!

Matthew May 29, 2020 - 11:03 pm

Thank you so much Jovan R. Your tip worked for me! After over a full day of trying, and this morning, I finally got my fans working on my Wacom Mobile Studio Pro that I put Xfce Linux Mint. Not sure why the panel matters so much of all things, but it seems to be the missing key! Another user here (https://forum.manjaro.org/t/xfce-power-management-settings-for-display-has-no-effect/69947/2) lists a similar experience where he fiddled around with his panel and suddenly got his fans to work without understanding quite how or why. This seems to me to be a bit of a mysterious problem with Linux, hopefully a concrete answer will emerge eventually!

jack July 12, 2020 - 2:38 pm

thank you very much,i from china,the banned internet, i am hopeless search by the countory alone se,thank you


Leave a Comment

* By using this form you agree with the storage and handling of your data by this website.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

This website uses cookies to improve your experience. We'll assume you're ok with this, but you can opt-out if you wish. Accept Read More