‘Glances’ is an extremely powerful command-line based system monitor that I came across a couple of years ago. It’s capable of monitoring various hardware devices (CPU, Memory, Swap-disks, Hard disk drives, Network connections, Processes, System load, Sensors etc) and provide alerts based upon their load. Due to its simplicity & the clever UI design, it makes the life of a server administrator easy.
The last time I tried it, it was only available for GNU/Linux (if I’m not mistaken), but since then a lot has changed. Now it’s available for GNU/Linux, Microsoft Window, Mac OS X and Android. Web based GUI & remote monitoring support, support for monitoring Dockers & Raid systems and logging the monitored data is also added (among others) to its features list as well.
Most desktop users won’t hugely benefit by using Glances, that said, if you play with the command-line a bit (or want to impress your friends 😀 ), it is a useful tool nevertheless. Installing it also is quite easy as many distributions (such as Ubuntu) include it on their servers these days.
So, as an Ubuntu user, if you want to give it a try on an Ubuntu server or a desktop environment, you can install its latest version using the below commands. I like this method as opposed to installing it using ‘apt’ as sometimes those pre-built packages could include somewhat outdated versions (please note that, I only tested it on Ubuntu 15.10):
Step 1: First let’s install a dependency. For that, open a terminal window and enter the below command:
sudo apt-get install python-psutil
Step 2: Now enter the below command to install Glances (make sure it exits without errors as shown below):
sudo pip install glances
If it exits with errors, then you can install the pre-built package from Ubuntu repository. For that, simply enter the below command:
sudo apt-get install glances
To run it, enter the below command:
To get a list of keyboard shortcuts, once opened, press the ‘H’ key. But if you’re serious about using Glances, then you should read its documentation. To get more information, please visit this page. Good luck & merry Christmas!.