Home>Article>Operation and Maintenance> How to query hard disk information in Linux
6 ways to query hard disk information: 1. Use the "df-h" command to output the hard disk usage status in a readable format; 2. Use the "lsblk" command to list the hard disk information; 3. . Use the "lshw" command to print detailed information about the hardware (including hard disk); 4. Use the "fdisk" command to print hard disk information; 5. Use the "cat /proc/partitions" command to view the current hard disk and partitions. Some information; 6. Use the lsscsi tool to print SCSI hard disk information.
#The operating environment of this tutorial: Red Hat Enterprise Linux 6.1 system, Dell G3 computer.
Linux query hard disk information
The firstdf-h
command can output the hard disk usage status in a readable format : As shown in the figure
#Second, use the "lsblk" command to list only the hard disk and not the partition information. An example is shown in the figure below
#Third, use the "lshw" command to print detailed information about the hardware. The example is as follows
Fourth, fdisk can be used to print hard disk information, the example is as follows:
Fifth, You can use the contents of the /proc/partitions file to view some information about the current hard disk and partitions. As shown in the picture
Sixth, use the lsscsi tool to print SCSI hard disk information, as shown in the picture:
Related recommendations: "Linux Video Tutorial"
The above is the detailed content of How to query hard disk information in Linux. For more information, please follow other related articles on the PHP Chinese website!