Linux: Keep An Eye On Your System With Glances Monitor

Is there is a tool that can provide me a maximum of information (such as cpu, disk I/O, network, nfsd, memory and more) about my Linux/Unix server in a minimum of space in a terminal?

There are plenty of monitoring tools on Linux or Unix-like systems that can provide information about your server:
  1. CPU load
  2. Tutorial details
    Difficulty level Easy
    Root privileges Yes
    Requirements Python+Terminal
    Est. reading time 10m
  3. OS Name/Kernel version
  4. System load
  5. Disk and Network I/O
  6. Process
  7. Memory usage
  8. Mount point and much more.

Say hello to Glances

From the project home page:

Glances is a free (LGPL) cross-platform curses-based monitoring tool which aims to present a maximum of information in a minimum of space, ideally to fit in a classical 80×24 terminal or higher to have additionnal information. Glances can adapt dynamically the displayed information depending on the terminal size. It can also work in a client/server mode for remote monitoring.

This utility is written in Python and uses the psutil library to fetch the statistical values from your server.


You can install Glances using pip command line tool. You will also find packages for Arch Linux, Fedora/CentOS/RHEL, Debian, Ubuntu (13.04+), FreeBSD, OSX and so you should be able to install it using your favorite package manager as follows:

Install Glances on CentOS/Fedora/RHEL/Scientific Linux

First, turn on Extra Packages for Enterprise Linux (or EPEL) repo on CentOS/RHEL/SL. Type the following yum command:
# yum -y install glances
Sample outputs:

yum install glances
Loaded plugins: product-id, protectbase, rhnplugin
This system is receiving updates from RHN Classic or RHN Satellite.
rhel-x86_64-server-6                                 | 1.5 kB     00:00     
rhel-x86_64-server-optional-6                        | 1.5 kB     00:00     
0 packages excluded due to repository protections
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package glances.noarch 0:1.7.1-1.el6 will be installed
--> Processing Dependency: python-psutil >= 0.4.1 for package: glances-1.7.1-1.el6.noarch
--> Processing Dependency: python-setuptools for package: glances-1.7.1-1.el6.noarch
--> Running transaction check
---> Package python-psutil.x86_64 0:0.6.1-1.el6 will be installed
---> Package python-setuptools.noarch 0:0.6.10-3.el6 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
 Package             Arch     Version          Repository              Size
 glances             noarch   1.7.1-1.el6      epel                   107 k
Installing for dependencies:
 python-psutil       x86_64   0.6.1-1.el6      epel                    84 k
 python-setuptools   noarch   0.6.10-3.el6     rhel-x86_64-server-6   336 k
Transaction Summary
Install       3 Package(s)
Total download size: 527 k
Installed size: 843 k
Is this ok [y/N]: y
Downloading Packages:
(1/3): glances-1.7.1-1.el6.noarch.rpm                | 107 kB     00:00     
(2/3): python-psutil-0.6.1-1.el6.x86_64.rpm          |  84 kB     00:00     
(3/3): python-setuptools-0.6.10-3.el6.noarch.rpm     | 336 kB     00:00     
Total                                       1.8 MB/s | 527 kB     00:00     
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing : python-psutil-0.6.1-1.el6.x86_64                         1/3 
  Installing : python-setuptools-0.6.10-3.el6.noarch                    2/3 
  Installing : glances-1.7.1-1.el6.noarch                               3/3 
  Verifying  : python-setuptools-0.6.10-3.el6.noarch                    1/3 
  Verifying  : python-psutil-0.6.1-1.el6.x86_64                         2/3 
  Verifying  : glances-1.7.1-1.el6.noarch                               3/3 
  glances.noarch 0:1.7.1-1.el6                                              
Dependency Installed:
  python-psutil.x86_64 0:0.6.1-1.el6                                        
  python-setuptools.noarch 0:0.6.10-3.el6                                   

Install Glances on Debian/Ubuntu Linux (13.04+)

Type the following command:
$ sudo apt-get install glances
Sample outputs:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following extra packages will be installed:
  python-jinja2 python-markupsafe python-psutil
Suggested packages:
The following NEW packages will be installed:
  glances python-jinja2 python-markupsafe python-psutil
0 upgraded, 4 newly installed, 0 to remove and 0 not upgraded.
Need to get 734 kB of archives.
After this operation, 2,429 kB of additional disk space will be used.
Do you want to continue? [Y/n] 
Get:1 trusty/main python-markupsafe amd64 0.18-1build2 [14.3 kB]
Get:2 trusty/main python-jinja2 all 2.7.2-2 [161 kB]
Get:3 trusty/main python-psutil amd64 1.2.1-1ubuntu2 [50.2 kB]
Get:4 trusty/universe glances all 1.7.3-2ubuntu1 [509 kB]
Fetched 734 kB in 0s (6,667 kB/s)
Selecting previously unselected package python-markupsafe.
(Reading database ... 64983 files and directories currently installed.)
Preparing to unpack .../python-markupsafe_0.18-1build2_amd64.deb ...
Unpacking python-markupsafe (0.18-1build2) ...
Selecting previously unselected package python-jinja2.
Preparing to unpack .../python-jinja2_2.7.2-2_all.deb ...
Unpacking python-jinja2 (2.7.2-2) ...
Selecting previously unselected package python-psutil.
Preparing to unpack .../python-psutil_1.2.1-1ubuntu2_amd64.deb ...
Unpacking python-psutil (1.2.1-1ubuntu2) ...
Selecting previously unselected package glances.
Preparing to unpack .../glances_1.7.3-2ubuntu1_all.deb ...
Unpacking glances (1.7.3-2ubuntu1) ...
Processing triggers for ureadahead (0.100.0-16) ...
ureadahead will be reprofiled on next reboot
Processing triggers for man-db ( ...
Setting up python-markupsafe (0.18-1build2) ...
Setting up python-jinja2 (2.7.2-2) ...
Setting up python-psutil (1.2.1-1ubuntu2) ...
Setting up glances (1.7.3-2ubuntu1) ...
Creating system user 'glances'.
 * Starting Glances server glances                                                                                  * Not starting glances: disabled by /etc/default/glances.
Processing triggers for ureadahead (0.100.0-16) ...

Turn on glances by editing the /etc/default/glances file, enter:
# vi /etc/default/glances
Update it as follows to ‘true’ to have glances running at startup:


Save and close the file. Start glances:
# service glances start

How do I use glances?

The basic syntax is:
# glances
# glances [options]

Sample outputs:

Fig.01: glances in action (click to enlarge)

To quit just press q (Esc and Ctrl-C also work). Here is another output from Ubuntu based system:

Fig.02: Glances in action (Image credit – Glances author)

HTML5 capable browser user can view quick video demo by clicking the following link:

Sorry, your browser doesn’t support HTML5 video.

(Video 01: Glances command in action)

Fine tuning output (interactive commands)

Use the following hot keys to find tune your output:

  • a Sort processes automatically.
  • c Sort processes by CPU%.
  • m Sort processes by MEM%.
  • p Sort processes by name.
  • i Sort processes by I/O rate.
  • d Show/hide disk I/O stats.
  • f Show/hide file system stats.
  • n Show/hide network stats.
  • s Show/hide sensors stats.
  • y Show/hide hddtemp stats.
  • l Show/hide logs.
  • b Bytes or bits for network I/O.
  • w Delete warning logs.
  • x Delete warning and critical logs.
  • 1 Global CPU or per-CPU stats.
  • t View network I/O as combination.
  • u – View cumulative network I/O.

How do I use Glances in client/server mode?

On server type the following command to bind server to the given IPv4/IPv6 address or hostname:
# glances -B @IP|host
# glances -B
# glances -B

From your desktop client such as OSX/FreeBSD/Linux based system type the following command to connect to a Glances server by IPv4/IPv6 address or hostname:
# glances -c @IP|host
# glances -c
# glances -c

You may need to pass the -P password to set a client/server password. The -s run Glances in server mode:

How do I refresh information every 5 seconds?

Type the following command:
# glances -t 5

How do I see all supported options?

This command has many more options, type the following command at shell prompt:
$ glances -h
Sample outputs:

Glances version 1.7.3 with PsUtil 1.2.1
Usage: glances [options]
	-b		Display network rate in Byte per second
	-B @IP|HOST	Bind server to the given IPv4/IPv6 address or hostname
	-c @IP|HOST	Connect to a Glances server by IPv4/IPv6 address or hostname
	-C FILE		Path to the configuration file
	-d		Disable disk I/O module
	-e		Enable sensors module
	-f FILE		Set the HTML output folder or CSV file
	-h		Display the help and exit
	-m		Disable mount module
	-n		Disable network module
	-o OUTPUT	Define additional output (available: HTML or CSV)
	-p PORT		Define the client/server TCP port (default: 61209)
	-P PASSWORD	Define a client/server password
	--password	Define a client/server password from the prompt
	-r		Disable process list
	-s		Run Glances in server mode
	-t SECONDS	Set refresh time in seconds (default: 3 sec)
	-v		Display the version and exit
	-y		Enable hddtemp module
	-z		Do not use the bold color attribute
	-1		Start Glances in per CPU mode
See also

Glances is not the only option. You can try:

🐧 Get the latest tutorials on Linux, Open Source & DevOps via RSS feed or Weekly email newsletter.

🐧 26 comments so far... add one

CategoryList of Unix and Linux commands
Disk space analyzersdf duf ncdu pydf
File Managementcat cp mkdir tree
FirewallAlpine Awall CentOS 8 OpenSUSE RHEL 8 Ubuntu 16.04 Ubuntu 18.04 Ubuntu 20.04
Modern utilitiesbat exa
Network UtilitiesNetHogs dig host ip nmap
OpenVPNCentOS 7 CentOS 8 Debian 10 Debian 8/9 Ubuntu 18.04 Ubuntu 20.04
Package Managerapk apt
Processes Managementbg chroot cron disown fg glances gtop jobs killall kill pidof pstree pwdx time vtop
Searchingag grep whereis which
User Informationgroups id lastcomm last lid/libuser-lid logname members users whoami who w
WireGuard VPNAlpine CentOS 8 Debian 10 Firewall Ubuntu 20.04
26 comments… add one
  • Leszek Dec 17, 2013 @ 21:25

    It looks nice and similar to Topas from AIX.

    • RakX Dec 18, 2013 @ 13:38

      It does look like topas…
      But nmon still rocks! ;-)

  • Aldric Dec 17, 2013 @ 21:49

    Just installed on Centos, work great !
    Thanks :)

  • Robert Butzke Dec 17, 2013 @ 22:07

    It looks a lot like RPM (Realtime Performance Monitor) on old DG/UX and AIX’s Topas. Will definitely give it a try on my FreeBSD systems.

    • Raju K Dec 17, 2013 @ 22:16

      Yuppi, it was easy :)

       cd /usr/ports/sysutils/py-glances/ && make install clean

      Freebsd has the precompiled binary package too:

      pkg_add -r py27-glances


      Thanks ba!

      Raju K.
      Yahoo India Data Center Technician.

      • Kiran Patil Dec 18, 2013 @ 10:41

        Nice…Pretty good tool… Thanks for Sharing Info.

  • niraj Dec 18, 2013 @ 5:21

    Its a good tool all in one.

  • Sunil Bhoi Dec 18, 2013 @ 8:15


    Thanks :) Great tool.

  • jkfromdevnull Dec 18, 2013 @ 10:08

    For Ubuntu LTS:

    sudo apt-add-repository ppa:arnaud-hartmann/glances-stable
    sudo apt-get update
    sudo apt-get install glances

    Some one may find this useful. Cheers mate.

    • Tim Aug 31, 2015 @ 12:27

      Ah. Thanks for this!

  • shivangpatel Dec 18, 2013 @ 14:06

    Looks nice…
    Just installing…

  • urcindalo Dec 18, 2013 @ 15:14

    It’s also in Gentoo’s portage.

  • Tommy Butler Dec 19, 2013 @ 0:55

    Doesn’t work on Debian 7 Wheezy. Not in Wheezy repo for main, contrib, or non-free.

    • yoann Oct 5, 2014 @ 0:57

      aptitude install python-dev python-pip
      pip install glances

  • TB Dec 21, 2013 @ 20:01

    Excellent tool. Just tested it on my CentOS.

  • CYBERWARE Dec 29, 2013 @ 16:30

    glances -o HTML -f /var/www/html/monitor.html
    Error: Need Jinja2 library to export into HTML
    Try to install the python-jinja2 package

  • D Jan 5, 2014 @ 5:58

    for Debian:

    sudo pip install glances

  • Ph Jan 12, 2014 @ 21:44

    Loved the tutorial. Just installed on CentOS. Thank you for sharing.

  • Euhill Feb 8, 2014 @ 19:14

    Gkrellm and Conky are a couple of good alternatives. Conky is quite popular as it puts the info on your desktop.

  • kamalkakkar Mar 3, 2014 @ 10:01


  • idroot Oct 5, 2014 @ 13:32

    awesome….:D useful tools,.

  • Tomek Jul 1, 2015 @ 6:15

    nice tool, thank you!

  • Joel Garcia Aug 31, 2015 @ 13:30

    Very usefull tool! Thanks a lot

  • Darren G Aug 31, 2015 @ 15:34

    Not too dissimilar from ‘atop’, though it looks like it has a much nicer layout :)

  • Khalil Sep 21, 2015 @ 20:59

    is it better than Conky ?

  • george Mar 27, 2017 @ 16:46

    Thank you for the Glances!!!!!:):):)

Leave a Reply

Your email address will not be published.

Use HTML <pre>...</pre> for code samples. Still have questions? Post it on our forum