"free" - Display Free and Used Memory

Provides a tutorial example on how to display free and used memory information using the 'free' command on Linux systems.

Another important information about your Linux system is the memory. You can use the "free" command to display memory statistics including free and used memory sizes. Here are some examples of "free" command output on my CentOS computer.

1. Display memory information using "free" with default options. The memory counts are displayed in kibibytes (1,024 bytes). Note that a kibibyte (1,024 bytes) is slightly different than a kilobyte (1,000 bytes).

herong$ free
           total     used     free   shared  buff/cache   available
Mem:     7789220  2047412   677256   297448     5064552     5145248
Swap:    8085500        0  8085500

2. To control the unit, you can use "free -b|k|m|g" options.

herong$ free -m
           total     used     free   shared  buff/cache   available
Mem:        7606     1999      661      290        4945        5024
Swap:       7895        0     7895

3. Or you can use "free -h" to display counts in human readable formats.

herong$ free -h
           total     used     free   shared  buff/cache   available
Mem:       7.4Gi    2.0Gi    661Mi    290Mi       4.8Gi       4.9Gi
Swap:      7.7Gi       0B    7.7Gi

The output columns are defined as:

Table of Contents

 About This Book

Introduction to Linux Systems

 "uname" - Display System Information

"free" - Display Free and Used Memory

 Cockpit - Web Portal for Administrator

 Process Management

 Files and Directories

 Users and Groups

 File Systems

 Block Devices and Partitions

 LVM (Logical Volume Manager)

 Installing CentOS

 SELinux - Security-Enhanced Linux

 Network Connection on CentOS

 Software Package Manager on CentOS - DNF and YUM

 Running Apache Web Server (httpd) on Linux Systems

 Running PHP Scripts on Linux Systems

 Running MySQL Database Server on Linux Systems

 Running Python Scripts on Linux Systems

 vsftpd - Very Secure FTP Daemon

 Postfix - Mail Transport Agent (MTA)

 Dovecot - IMAP and POP3 Server

 Email Client Tools - Mail User Agents (MUA)

 LDAP (Lightweight Directory Access Protocol)

 GCC - C/C++ Compiler

 Graphics Environments on Linux

 Conda - Environment and Package Manager

 Tools and Utilities

 Administrative Tasks


 Full Version in PDF/EPUB