The CPU inside your computer is a very complex bit of electronics that can probably do an awful lot of number crunching. All this mathematical muscle generates heat, though, and a hot processor isn't a happy processor. Keeping an eye on your CPU temperature (and other temperatures in your system if you can) is a useful thing to do.
KDE includes a handy program for this sort of thing called KSensors. In this quick tutorial, I'm going to show you how to get up and running to get a KSensors temperature monitor for your KDE system tray. I'm using Kubuntu Feisty, but the steps here should work for most distributions.
On Linux, KSensors is a frontend for the Linux lm-sensors technology, so you'll need to have that setup first. For (K)ubuntu, there's a nice howto for that here, although it should be a case of installing lm-sensors and running the sensors-detect script (basically answering yes to everything). On my system, that's:
$ sudo apt-get install lm-sensors
$ sudo sensors-detect
Once that's done, you're ready for installing KSensors. Again, on Kubuntu:
$ sudo apt-get install ksensors
Once you're installed, launch KSensors from the K menu, or type ksensors in the Alt-F2 Run Command dialogue and press Enter. You'll get a small icon in your system tray and a blank 'canvas' window where you can drop sensors that looks something like this:
We don't actually want this window for this tutorial (although you can drop sensors into it yourself if you wish, personally I prefer the temperatures up in the system tray). Right-click the KSensors icon and choose Minimise to get rid of the canvas-type window.
Now you've got just the tray icon up there. Right-click it again and choose Configure. The exact layout of the dialogue might differ depending on your hardware setup and what sensors are available to you. On my system, that involves going to the MainBoard sensors divider.
You can set a maximum value that you're happy with. If the temperature goes above that value, the sensor will change from green to red. The important part here, though, is going to the Dock tab and ticking Visible.
After clicking Apply, you should get something a little like this in your tray:
It is that simple. Now this is all well and good, but you may well want KSensors to start when you login. For KDE (which the tutorial is obviously aimed at), you need to add an entry into your Autostart folder. To do that, right-click an empty part of the desktop and do Create New > Link to Application. Presentation doesn't matter, here we're interested in the Application tab. In the Command box, type ksensors and click OK.
Open up your home folder and browse to the .kde folder (use View > Show Hidden files or type the path in). In there, go into Autostart and move that launcher we just created into that folder.
Now your KSensors tray will open up every time you log in to KDE.
And that's it - we're done! Of course, feel free to customise your KSensors install; if your system supports it, you might have other temperatures you can monitor too which you can add in a similar way to the CPU temperature.
Calling all FOSSwire readers! We’re looking for your feedback - answer our reader survey and you could win an awesome FOSSwire t-shirt (we’ll ship anywhere on this planet).