当前位置:首页 > 服务器 > 正文

怎么查看服务器有几块硬盘(如何查看服务器上还插多少硬盘)

如何查看服务器上的硬盘数量
要素:
使用命令行工具 "fdisk"

fdisk -l

查看分区表

sudo fdisk -l

输出示例:
Disk /dev/sda: 1000.2 GB, 1000204886016 bytes, 1953525168 sectors
Disk model: VMware Virtual disk
Units: sectors of 1 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 5FC0A878-2EF4-40D9-A976-BE35095F2075
Device Start End Sectors Size Type
/dev/sda1 1048576 14680063 13631488 6.5G Linux filesystem
/dev/sda2 14680064 1953525167 1806724504 859G Linux filesystem
在这个示例中,服务器上有两块硬盘:/dev/sda 和 /dev/sda2。