Glances is a real-time system monitoring tool written in Python language. It monitors system resources, including CPU, Memory, Load, Disk I/O, Processes, File System space, Network interface, and more. It also offers a web-based interface that allows you to monitor system resources from the remote system over the internet.
Here at Ibmi Media, as part of our Server Management Services, we regularly help our Customers to perform related System Monitoring queries on Linux Systems.
In this context, we shall look into how to install and get started with the Glances monitoring tool on Ubuntu 20.04 LTS.
Ubuntu OS has Glances in its repositories, so you can install it easily using the apt command. Follow the below steps to install Glances on Linux Ubuntu via apt.
i. To install Glances, use the command below in the Terminal:
$ sudo apt install glances
Enter your sudo password, and if you are asked for confirmation during installation, type y and press Enter.
After the installation of Glances is completed, you can use the command below for the verification:
$ glances --version
Glances is also available as a snap package. Follow the below steps to install Glances on Linux Ubuntu via snap:
i. First install snapd using this command:
$ sudo apt install snapd
Enter your sudo password, and if you are asked for confirmation during installation, type y and press Enter.
ii. Now install Glances using this command:
$ sudo snap install glances
iii. After the installation of Glances is completed, you can use this command for the verification:
$ glances --version
In order to use Glances to monitor system resources, use the command below:
$ glances
This will display the Glances interface.
To access Glances interface from the web browser, use the glances command with -w option:
$ glances -w
The output of the above command will tell you that the web UI has started. Now open the web browser and navigate to the below address:
http://<glances-IP-address>:61208
If you need to access the Glances web UI from another system on the network, then you will have to allow port 61208 on the firewall of the Glances server. To allow port 61208 on the firewall, use the command below:
$ sudo ufw allow 61208
Then run this command in the Terminal of Glances server:
$ glances -w
Now from the other system, open the web browser and navigate to the below address to access Glances web UI:
http ://<glances-IP-address>:61208
In order to uninstall Glances from Ubuntu machine, execute the command below:
$ sudo apt remove glances
Enter your sudo password, and if you are asked for confirmation during uninstallation, type y and press Enter.
This article covers how to install and get started with the Glances monitoring tool on Ubuntu.
To view more help, you can use the glances –help command.
By default, Glances is included in the Ubuntu default repository. You can install it with the following command:
$ apt-get install glances -y
After installing Glances, verify the installed version of Glances using the following command:
$ glances --version
Glances monitors and display the information about: