Disk /dev/sda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 1 9729 78148161 fd Linux raid autodetect
Disk /dev/sdb: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 1 9729 78148161 8e Linux LVM
Disk /dev/sdc: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdc1 1 9729 78148161 fd Linux raid autodetect
以上是我做RAID5的三块80GB的硬盘并且按照书上说的对每块硬盘做了全盘的分区。
接下来我创建RAID5
[root@RAID lvtest1]# mdadm -Cv /dev/md1 -l5 -n3 /dev/sda1 /dev/sdb1 /dev/sdc1
mdadm: layout defaults to left-symmetric
mdadm: chunk size defaults to 64K
mdadm: /dev/sda1 appears to be part of a raid array:
level=raid5 devices=3 ctime=Tue Sep 15 14:54:01 2009
mdadm: /dev/sdb1 appears to be part of a raid array:
level=raid5 devices=3 ctime=Tue Sep 15 14:54:01 2009
mdadm: /dev/sdc1 appears to be part of a raid array:
level=raid5 devices=3 ctime=Tue Sep 15 14:54:01 2009
mdadm: size set to 20482752K
mdadm: largest drive (/dev/sda1) exceed size (20482752K) by more than 1%
Continue creating array? y
mdadm: array /dev/md1 started.
可是我的RAID5为什么容量只有41.9GB
[root@RAID lvtest1]# fdisk -l /dev/md1
Disk /dev/md1: 41.9 GB, 41948676096 bytes
2 heads, 4 sectors/track, 10241376 cylinders
Units = cylinders of 8 * 512 = 4096 bytes
Disk /dev/md1 doesn't contain a valid partition table


linux_jie 于 2011-04-26 22:22:14发表:
160G