我有3个3TB驱动器,并让raid5ed它们在一起。我希望能得到一个大约6TB的结果设备。我使用的命令:
mdadm --create md0 --level=5 --raid-devices=3 /dev/sda1 /dev/sdb1 /dev/sdc1还注意到:
# fdisk -l | grep 'Disk /dev/sd'
Disk /dev/md0 doesn't contain a valid partition table
Disk /dev/mapper/root doesn't contain a valid partition table
Disk /dev/mapper/swap_1 doesn't contain a valid partition table
Disk /dev/sda: 3000.6 GB, 3000592982016 bytes
Disk /dev/sdb: 3000.6 GB, 3000592982016 bytes
Disk /dev/sdc: 3000.6 GB, 3000592982016 bytes
Disk /dev/sdd: 320.1 GB, 320072933376 bytes
# mdadm --detail /dev/md0
md0:
Version : 1.2
Creation Time : Wed Jul 10 17:11:04 2013
Raid Level : raid5
Array Size : 4294702080 (4095.75 GiB 4397.77 GB)
Used Dev Size : 2147351040 (2047.87 GiB 2198.89 GB)
Raid Devices : 3
Total Devices : 3
Persistence : Superblock is persistent
Update Time : Thu Jul 11 14:51:17 2013
State : clean
Active Devices : 3
Working Devices : 3
Failed Devices : 0
Spare Devices : 0
Layout : left-symmetric
Chunk Size : 512K
Name : ...
UUID : 6331582a:92950387:4e4e7314:8bccf9cb
Events : 66195
Number Major Minor RaidDevice State
0 8 1 0 active sync /dev/sda1
1 8 17 1 active sync /dev/sdb1
3 8 33 2 active sync /dev/sdc1
#如果能提供更多的信息,请告诉我。
发布于 2013-07-11 20:27:19
你第一次是如何划分磁盘的?如果您使用fdisk,您可能限制在每个磁盘的前2TB,因为这是您可以用fdisk创建的最大分区大小。因此,您的raid设备看起来可能更像一个3* 2TB磁盘的RAID5。
使用parted创建大于2TB的分区。
示例:
[root@evil home]# parted /dev/sda -- mklabel GPT yes unit TB mkpart primary ext2 0 -1
Warning: The existing disk label on /dev/sda will be destroyed and all data on this disk will be lost. Do you want to continue?
Information: You may need to update /etc/fstab.
[root@evil home]#对每个驱动器都这样做,然后重新创建您的RAID5设备,看看是否允许您使用其余的驱动器。
在按照上述命令行重置分区表之后,可以使用parted /dev/sda -- print查看分区表。
发布于 2013-07-12 13:05:48
没有必要预先格式化磁盘;mdadm可以为您处理这个问题!
# mdadm --create md0 --level=5 --raid-devices=3 /dev/sda /dev/sdb /dev/sdc这应该在任何分区之前完成。
https://unix.stackexchange.com/questions/82681
复制相似问题