To check the RAM (random access memory) size on a Red Hat Linux desktop system, you can use the free
command. The free
command is a utility that displays information about the system's memory usage, including the total amount of RAM and the amount of used and available RAM.
To use the free
command, open a terminal and enter the following command:
free -h
The -h
option tells the free
command to display the sizes of the memory in "human-readable" format, which means that the sizes are displayed in a more convenient format, such as in megabytes (MB) or gigabytes (GB).
The output of the free
command will show the total amount of RAM, the amount of used RAM, the amount of free RAM, and the amount of shared RAM. For example, the output might look something like this:
total used free shared buff/cache available Mem: 7.7G 1.9G 3.4G 164M 2.4G 5.3G Swap: 7.9G 0B 7.9G
To check the RAM size on a specific type of memory (such as the main memory or the swap memory), you can use the -m
option to display the sizes in megabytes, or the -g
option to display the sizes in gigabytes. For example, to display the RAM size in megabytes, you can use the following command:
free -m
This will display the total, used
free -m will display the total, used memory and free memory:
total used free shared buff/cache available Mem: 990 645 97 0 247 29