2015/03/18

14 commands to check hardware information in Pisi LInux

14 commands to check Hardware Information

For a while i have post here Information about Hardware and System Information in three Parts.

Part 1: Hardware and Systeminformation from Commandline in Pisi Linux Part1 the lshw command

Part 2: Hardware and Systeminformation from Commandline in Pisi Linux Part 2 the dmidecode

Part 3: Hardware and Systeminformation from Commandline in Pisi Linux Part 3 inxi

Now here have you a little overview about a lot of more commands, this commands works for the most Linux Distributions ( such as Debian based or other).
You become here the commands with a little Image for Pisi Linux so that you can see it works, and Pisi Linux give you Hardware Information such as the most Linux Distributions.

1. lscpu
The lscpu command reports information about the cpu and processing units. It does not have any further options or functionality.



2. lshw - List Hardware

A general purpose utility, that reports detailed and brief information about multiple different hardware units such as cpu, memory, disk, usb controllers, network adapters etc. Lshw extracts the information from different /proc files.



Read the following Page to learn more about the lshw command:

3.lspci - List PCI

The lspci command lists out all the pci buses and details about the devices connected to them.
The vga adapter, graphics card, network adapter, usb ports, sata controllers, etc all fall under this category.


Filter out specific device information with grep.

$ lspci -v | grep "VGA" -A 12




4. lsscsi - List scsi devices

Lists out the scsi/sata devices like hard drives and optical drives.

Note for this command you must install in Pisi Linux the package lsscsi, simple with the command:

$ sudo pisi it lsscsi



5. lsusb - List usb buses and device details

This command shows the USB controllers and details about devices connected to them. By default brief information is printed. Use the verbose option "-v" to print detailed information about each usb port


On the above Image you can see, 1 usb port is being used by the mouse, and one i using by the Keyboard

.6. Inxi

Inxi is a 10K line mega bash script that fetches hardware details from multiple different sources and commands on the system, and generates a beautiful looking report that non technical users can read easily.

$ inxi -Fx




For more inxi commands can you read this page:


7. lsblk - List block devices

List out information all block devices, which are the hard drive partitions and other storage devices like optical drives and flash drives


8. df - disk space of file systems

Reports various partitions, their mount points and the used and available space on each.



9. fdisk

Fdisk is a utility to modify partitions on hard drives, and can be used to list out the partition information as well.



10. mount

The mount is used to mount/unmount and view mounted file systems.


And again, use grep to filter out only those file systems that you want to see

$ mount | column -t | grep ext



11. free - Check RAM

Check the amount of used, free and total amount of RAM on system with the free command.




12. dmidecode

The dmidecode command is different from all other commands. It extracts hardware information by reading data from the SMBOIS data structures (also called DMI tables).


display information about the processor/cpu
$ sudo dmidecode -t processor 
# memory/ram information 
$ sudo dmidecode -t memory 
# bios details 
$ sudo dmidecode -t bios




13. /proc files



Many of the virtual files in the /proc directory contain information about hardware and configurations. Here are some of them

CPU/Memory information


# cpu information
$ cat /proc/cpuinfo 
# memory information 
$ cat /proc/meminfo



Linux/kernel information





SCSI/Sata devices



Partitions





14. hdparm

The hdparm command gets information about sata devices like hard disks.






Each of the command has a slightly different method of extracting information, and you may need to try more than one of them, while looking for specific hardware details. However they are available across most linux distros, and can be easily installed from the default repositories.

On the desktop there are gui tools, for those who do not want to memorise and type commands. Hardinfo, I-nex are some of the popular ones that provide detailed information about multiple different hardware components.