check the system configuration in Linux

To know only the system name, you can use the uname command without any switch that will print system information or the uname -s command will print the kernel name of your system.

$ uname

To view your network hostname, use the ‘-n’ switch with the uname command as shown.

$ uname -n

To get information about kernel-version, use the ‘-v’ switch.

$ uname -v

To get the information about your kernel release, use the ‘-r’ switch.

$ uname -r

To print your machine hardware name, use the ‘-m’ switch:

$ uname -m

All this information can be printed at once by running the ‘uname -a’ command as shown below.

$ uname -a

lshw is a relatively small tool and there are few options that you can use with it while extracting information. The information provided by lshw was gathered from different /proc files.

$ sudo lshw

You can print a summary of your hardware information by using the -short option.

$ sudo lshw -short

If you wish to generate output as an html file, you can use the option -html.

$ sudo lshw -html > lshw.html

To view information about your CPU, use the lscpu command as it shows information about your CPU architecture such as a number of CPUs, cores, CPU family model, CPU caches, threads, etc from sysfs and /proc/cpuinfo.

$ lscpu

lsblk command is used to report information about block devices as follows.

$ lsblk 

If you want to view all block devices on your system then include the -a option.

$ lsblk -a

The lsusb command is used to report information about USB controllers and all the devices that are connected to them.

$ lsusb

You can use the -v option to generate detailed information about each USB device.

$ lsusb -v


Leave a Reply