List of Commands to get Linux system info using terminal

In Linux, we can use the command terminal to check various system hardware configurations and information such as CPU, Memory, hard disk, etc., and here are those to use…

Although there are tools that can display Linux system info graphically, however, here we are going to use the inbuilt commands.

The question of how a system is equipped and how it performs in harsh everyday life is not only of theoretical interest. Lot’s of time to solve a problem we need to know hardware and its utilization to remove some bottleneck. Thus, if you are new to Linux systems or running any cloud server where you want to know about the system load, the network interface, and type of processor and chipset, or what hardware is actually in the system? Then here some top commands to follow…

Commands to View Linux System info using terminal

Here we are using Ubuntu 20.04 to display the results of the Linux system info commands, however, you can use them on older versions such as Ubuntu 18.04/16.04 including RPM-based distros like CentOS and RHEL. Apart from them, others are also supported such as Debian, Linux Mint, Kali, Elementary OS, Manjaro, and more.

1. Check Linux system CPU info and Virtualization support

To check out the full information of Linux system’s CPU such as Type of  Architecture (i386, x86_64, etc.) (32-bit or 64-bit), Socket, Cores per socket, CPU speed, L cache, Virtualization type or support, etc. use the below given single command:


Check Linux system info - CPU and Virtualization

Furthermore, you can also check each CPU in detail (CPU model, frequency, etc.) of your computer, laptop, or server using:

cat /proc/cpuinfo


Processor : 01
vendor_id : GenuineIntel
cpu family : 6
model : 58
model name : Intel(R) Core(TM) i7-3770 CPU @ 3.40GHz
stepping : 9
microcode : 0x21
cpu MHz : 3392.293
cache size : 8192 KB
physical id : 0
siblings : 1
core id : 0

2. Know about Linux System RAM details

Check out free Memory on your Linux system along with details of its size and hardware information.

To print free available RAM, type:

free -m

Those who are interested in full detail such as Total Memory, Free Memory, Buffers, Cache, Swap cached, Active, mapped, and more… can go for this one:

cat /proc/meminfo

Check Free RAM and other details of Memory using command min

To identify each RAM used on each memory slot of your system’s motherboard, print the Memory Controller information using the dmidecode command:

sudo dmidecode -t memory

Get Each RAM DIMM slot info on Linux system min

3. Find out BIOS Info on Linux using Dmidecode

Dmidecode dumps the DMI (Desktop Management Interface) information of the machine in a readable way. This information includes hardware and BIOS.

You can get the current configuration and the maximum configuration supported by the system, such as the maximum amount of memory supported that we already have shown above…

Therefore, here are some uses of the dmidecode command to know further details of the system as well such as BIOS version, motherboard, and processor.

sudo dmidecode -t system
sudo dmidecode -t bios
sudo dmidecode -t processor

If you want to view all Linux useful system information use this one. However, it will give a lot of information.

sudo dmidecode -q

Command to check Linux systems BIOS information


4. Command to view hard disk and partition distribution

Do you want to know about each size of Hard disk and partition available? Then use-



[email protected]:~$ lsblk
loop0 7:0 0 1.9G 1 loop /rofs
loop1 7:1 0 27.1M 1 loop /snap/snapd/7264
loop2 7:2 0 55M 1 loop /snap/core18/1705
loop3 7:3 0 240.8M 1 loop /snap/gnome-3-34-1804/24
loop4 7:4 0 62.1M 1 loop /snap/gtk-common-themes/1506
loop5 7:5 0 49.8M 1 loop /snap/snap-store/433
sda 8:0 0 20G 0 disk 
├─sda1 8:1 0 512M 0 part 
├─sda2 8:2 0 1K 0 part 
└─sda5 8:5 0 19.5G 0 part 
sr0 11:0 1 2.5G 0 rom /cdrom

Furthermore, those who want to dig more on hard disk and partitions, then to have each detail of the installed drives run fdisk -l with sudo rights:

sudo fdisk -l


Disk /dev/loop0: 1.93 GiB, 2049204224 bytes, 4002352 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

Disk /dev/loop1: 27.9 MiB, 28405760 bytes, 55480 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

To get a clear view and all information along with the type of file system and partitions mounted points, we can also use:

df -h

Mount points can be further elaborated with:

mount | column -t

hard disk info

5. Check Network card information

The network card installed on our Linux system is one of the important components to connect the internet and other local networks. However, to know its model, manufacturer, and other information without operating the system’s case, use the below-given commands.

lspci | grep -i 'eth'

Find out the IP address and available active ethernet interfaces:

ip addr

Now, after using the above command you get the IP address and active ethernet interface, just use that with the below command. For example, ens33 is our interface.

ethtool ens33

The ethtool will show all information about the network card bandwidth such as what is the max speed, supported link modes, ports, and more…

Command to get all information about installed Network card on Linux system

To get network information we can also use Net-tools, however, we need to install it because by default it would not available on the system.

For Debian/Ubuntu: sudo ap tinstall net-tools
For RHEL/CentOS/Fedorasudo yum install net-tools or sudo dnf install net-tools

To know Ipaddress:

ifconfig -a

For getting details of active connections, protocols, domain sockets, and more…

netstat -a


6. View PCI Slots information on Linux system

PCI slots, where we use graphic cards, network cards, and other third-party hardware directly on the Motherboard. To know about these PCI hardware slots run:


If you want more detailed information: lspci -v or lspci -vv

To see the device tree: lscpi -t

Linux system PCI cards information


6. USB controllers and attached devices

View the details of USB slots and the devices plugged into them using lsusb command:


To have detailed info on USB slots and their active devices use :

lsusb -v

Get USB controller info using command

7. Command to get complete Linux OS information

When we are running a Linux server and after upgrading or having installation, in case we want to know what version of Linux operating system we are using then, that is possible as well using the command terminal.

cat /etc/os-release
lsb_release -a

Get release info only: 

cat /etc/issue

Command to check Linux OS version min


8. Command to get Linux Kernel Information

A kernel, which is the core part of our Linux system, to check out which version we on before updating or after, run:

cat /proc/version
uname -r


9. View Real-time processes

To go a bit further and know PID (Process ID, Unique number of the process) of the process executed on the system along with what is currently active we can use two commands:

To check out the PID (Process ID, Unique number of the process) of the process.

ps -ef

Real-time display of process status


A top is a text-based tool that gives complete information of currently active processes in real-time. To exit it, press Ctrl+C.

top command

9. Complete Linux System Hardware Information

Here is the one final command that can give all the hardware information of your Linux system in a single shot. However, displaying all data in one place may feel clutter but if you don’t want to use multiple commands, then this one is for you.

sudo lshw

lshw command

Those who want to omit the slight unwanted information can use the same command with a short flag.

sudo lshw -short

linux info command CPU and memory command

The good thing, if you want to print or save your Linux system hardware information in HTML format then that is also possible using lshw, simply run:

sudo lshw -html > lshw-info.html

you will see the created file.

Now, open your browser and type or paste: file:///home/ubuntu/lshw-info.html

print or save linux hardware info in html using browser

Closing thoughts:

So, these were some common commands we can use to find out Linux system info on CPU, Memory, OS, kernel, Network, and more. Although, these are not the only there are so many others, so keep searching this big world of Linux. If you know some commands to get a better view of the Linux system then the comment section is all yours…


Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.