![希捷 4 TB 硬盘只能识别 2 TB](https://linux22.com/image/1061093/%E5%B8%8C%E6%8D%B7%204%20TB%20%E7%A1%AC%E7%9B%98%E5%8F%AA%E8%83%BD%E8%AF%86%E5%88%AB%202%20TB.png)
在同一台服务器上,我有一堆 4 TB 的 Seagate 磁盘。我刚刚安装了它们,发现有些被识别为 4 TB,但有些被识别为 2 TB。问题可能出在哪里?
$ dmesg | grep '8:0:3:0'
[ 10.810825] scsi 8:0:3:0: Direct-Access ATA ST4000DM005-2DP1 0001 PQ: 0 ANSI: 5
[ 11.508060] sd 8:0:3:0: [sdf] 7814037168 512-byte logical blocks: (4.00 TB/3.64 TiB)
[ 11.508061] sd 8:0:3:0: [sdf] 4096-byte physical blocks
[ 11.508064] sd 8:0:3:0: Attached scsi generic sg5 type 0
[ 11.508089] sd 8:0:3:0: [sdf] Write Protect is off
[ 11.508090] sd 8:0:3:0: [sdf] Mode Sense: 00 3a 00 00
[ 11.508100] sd 8:0:3:0: [sdf] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[ 11.524947] sd 8:0:3:0: [sdf] Attached SCSI disk
$ dmesg | grep 9:0:4:0
[ 13.235315] scsi 9:0:4:0: Direct-Access ATA ST4000DM005-2DP1 0001 PQ: 0 ANSI: 5
[ 13.240191] sd 9:0:4:0: Attached scsi generic sg14 type 0
[ 13.241734] sd 9:0:4:0: [sdo] 4294967294 512-byte logical blocks: (2.20 TB/2.00 TiB)
[ 13.278030] sd 9:0:4:0: [sdo] Write Protect is off
[ 13.278031] sd 9:0:4:0: [sdo] Mode Sense: 73 00 00 08
[ 13.280316] sd 9:0:4:0: [sdo] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[ 13.392557] sd 9:0:4:0: [sdo] Attached SCSI disk
smartctl 显示两个驱动器都是 4 TB。parted 分别将它们视为 4 TB 和 2 TB:
$ parted /dev/sdf unit s print
Model: ATA ST4000DM005-2DP1 (scsi)
Disk /dev/sdf: 7814037168s
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags:
Number Start End Size File system Name Flags
1 2048s 7814035455s 7814033408s primary raid
$ parted /dev/sdo unit s print
Model: ATA ST4000DM005-2DP1 (scsi)
Disk /dev/sdo: 4294967294s
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags:
Number Start End Size File system Name Flags
1 2048s 4294965247s 4294963200s primary raid
更新:
问题似乎是某些驱动器连接到 LSI SAS1068E SCSI 存储控制器,并且其中一个驱动器有 2 TB 的驱动器限制。
不确定是否有办法解决这个问题。:-(
答案1
驱动器为 RAID 格式。只要 RAID 显示为 4G 或 8G,就没问题。如果 RAID 显示为其他内容,则您的某个 GPT 分区表已损坏,需要重写。
答案2
尝试这个(擦除磁盘分区使其清空后):
parted /dev/sdo
mklabel gpt
mkpart primary 0GB 4096GB
您可以将“primary”替换为分区的其他名称。
“4096GB”对应于磁盘的最大可用大小,因此您可能必须将其降低以匹配实际可用空间,例如“3906GB”等。
您应该能够使用 fdisk 检查可用空间:
fdisk /dev/sdo
然后输入页列出分区和驱动器数据。
如果一切正常,您应该在 parted 中看到该驱动器为 4TB,如果是这样,只需使用 mkfs 和 mount 照常进行格式化和安装即可。