Creating an md with 3TB drives.
Hi guys.
I have two 3TB drives and I want to set them up as RAID0. The problem is I can't use all of the space on them. I only get 4TB of the 6 in total.
What I tried was:
# parted /dev/sde GNU Parted 2.3 Using /dev/sde Welcome to GNU Parted! Type 'help' to view a list of commands. (parted) mklabel gpt Warning: The existing disk label on /dev/sde will be destroyed and all data on this disk will be lost. Do you want to continue? Yes/No? yes (parted) mkpart primary 0 -0 Warning: The resulting partition is not properly aligned for best performance. Ignore/Cancel? ignore (parted) print Model: ATA Hitachi HDS72303 (scsi) Disk /dev/sde: 3001GB Sector size (logical/physical): 512B/512B Partition Table: gpt
Number Start End Size File system Name Flags 1 17.4kB 3001GB 3001GB primary
(parted) quit
Then I used fdisk to change the partition type to Linux raid auto
Finally I ran
mdadm --create /dev/md2 --level=0 --raid-devices=2 /dev/sdd1 /dev/sde1
but mdadm -QD /dev/md2 shows 2TBs are gone.
Array Size : 4294964224 (4096.00 GiB 4398.04 GB)
What to do in this case? How can I a 6TB raid array ?
Signature · 1 line
Marcin M. Jessa
Quoted 27 lines · On Wed, 28 Sep 2011 10:05:19 +0200 "Marcin M. Jessa" <[email protected]> wrote:
Hi guys.
I have two 3TB drives and I want to set them up as RAID0. The problem is I can't use all of the space on them. I only get 4TB of the 6 in total.
What I tried was:
# parted /dev/sde GNU Parted 2.3 Using /dev/sde Welcome to GNU Parted! Type 'help' to view a list of commands. (parted) mklabel gpt Warning: The existing disk label on /dev/sde will be destroyed and all data on this disk will be lost. Do you want to continue? Yes/No? yes (parted) mkpart primary 0 -0 Warning: The resulting partition is not properly aligned for best performance. Ignore/Cancel? ignore (parted) print Model: ATA Hitachi HDS72303 (scsi) Disk /dev/sde: 3001GB Sector size (logical/physical): 512B/512B Partition Table: gpt
Quoted 2 lines
Number Start End Size File system Name Flags
1 17.4kB 3001GB 3001GB primary
I wouldn't bother with a partition table - just use the whole device. But partition tables should work if you want that.
Quoted 4 lines
(parted) quit
Then I used fdisk to change the partition type to Linux raid auto
You can do that if you like but it will have no effect. The "raid auto" partition type only means anything on MBR partitions. You don't need to, so don't bother.
Quoted 9 lines
Finally I ran
mdadm --create/dev/md2--level=0 --raid-devices=2/dev/sdd1/dev/sde1but mdadm -QD
/dev/md2shows 2TBs are gone.
Array Size : 4294964224 (4096.00 GiB 4398.04 GB)What to do in this case? How can I a 6TB raid array ?
Hmm... maybe you have an old version of mdadm.
Or maybe mdadm is broken.
Please report:
mdadm -E /dev/sdd1 /dev/sde1
blockdev --getsz /dev/md2
cat /proc/mdstat
NeilBrown
Quoted 1 line
On 9/28/11 10:23 AM, NeilBrown wrote:
[...]
Quoted 6 lines
Quoted 2 lines
Then I used fdisk to change the partition type to Linux raid auto
You can do that if you like but it will have no effect. The "raid auto" partition type only means anything on MBR partitions. You don't need to, so don't bother.
Thanks Neil.
Not using fdisk worked like a charm.
# mdadm -QD /dev/md2
mdadm: bad uuid: UUID=aaa23fb6:a7bce189:b5293030:df5c4a2
/dev/md2:
Version : 1.2
Creation Time : Wed Sep 28 10:27:31 2011
Raid Level : raid0
Array Size : 5860530176 (5589.04 GiB 6001.18 GB)
Raid Devices : 2
Total Devices : 2
Persistence : Superblock is persistent Update Time : Wed Sep 28 10:27:31 2011
State : clean
Active Devices : 2
Working Devices : 2
Failed Devices : 0
Spare Devices : 0
Chunk Size : 512K
Name : odin:2 (local to host odin) UUID : 5577bbc0:8ec6a7ff:07aff1ed:5610061c
Events : 0
Number Major Minor RaidDevice State
0 8 49 0 active sync /dev/sdd1
1 8 65 1 active sync /dev/sde1
Signature · 1 line
Marcin M. Jessa
Quoted 6 lines · Marcin M. Jessa
On 9/28/11 10:23 AM, NeilBrown wrote:
[...]Quoted 3 lines
Quoted 2 lines
Then I used fdisk to change the partition type to Linux raid auto
Quoted 8 lines
Quoted 4 lines
You can do that if you like but it will have no effect. The "raid auto" partition type only means anything on MBR partitions. You don't need to, so
don't bother.Thanks Neil.
Not using fdisk worked like a charm.
Using fdisk probably resulted in the disks going over to MBR rather than GPT, and thus you have a 2TB limit.
By the way, you should probably try the parted again and fix the alignment issue (rather than just "ignoring" it) - it will make a /big/ difference.
Quoted 16 lines · David Brown
Quoted 6 lines · Marcin M. Jessa
On 9/28/11 10:23 AM, NeilBrown wrote:
[...]Quoted 3 lines
Quoted 2 lines
Then I used fdisk to change the partition type to Linux raid auto
Quoted 8 lines
Quoted 4 lines
You can do that if you like but it will have no effect. The "raid auto" partition type only means anything on MBR partitions. You don't need to, so
don't bother.Thanks Neil.
Not using fdisk worked like a charm.
Quoted 6 lines
Using fdisk probably resulted in the disks going over to MBR rather than GPT, and thus you have a 2TB limit.
By the way, you should probably try the parted again and fix the alignment issue (rather than just "ignoring" it) - it will make a /big/ difference.
In terms of speed?
This RAID array is temporarily just so I can back up/restore my broken 5x2TB RAID6 but it would be interesting to know what to do. I was running
# parted -a optimal /dev/sdd which was suppose to fix that warning but it didn't.
Signature · 1 line
Marcin M. Jessa
Quoted 24 lines · Marcin M. Jessa
Quoted 16 lines · David Brown
Quoted 6 lines · Marcin M. Jessa
On 9/28/11 10:23 AM, NeilBrown wrote:
[...]Quoted 3 lines
Quoted 2 lines
Then I used fdisk to change the partition type to Linux raid auto
Quoted 8 lines
Quoted 4 lines
You can do that if you like but it will have no effect. The "raid auto" partition type only means anything on MBR partitions. You don't need to, so
don't bother.Thanks Neil.
Not using fdisk worked like a charm.Quoted 6 lines
Using fdisk probably resulted in the disks going over to MBR rather than GPT, and thus you have a 2TB limit.
By the way, you should probably try the parted again and fix the alignment issue (rather than just "ignoring" it) - it will make a /big/ difference.
Quoted 7 lines
In terms of speed?
This RAID array is temporarily just so I can back up/restore my broken 5x2TB RAID6 but it would be interesting to know what to do. I was running# parted -a optimal /dev/sdd which was suppose to fix that warning but it didn't.
Yes, I was thinking in terms of speed. I haven't gone beyond 2 TB disks with MBR myself, so I can't comment on whether your partitions really are misaligned, or if it is just an incorrect warning. But if these disks are like most 2 TB disks with 4K sectors but which lie and claim to have 512 byte sectors (for compatibility with ancient and inferior OS'es), then partition misalignment will be major performance hit. It's worth double-checking that you've got it right here, before you go to far with the array.
Quoted 34 lines · David Brown
Quoted 25 lines · Marcin M. Jessa
Quoted 17 lines · David Brown
Quoted 6 lines · Marcin M. Jessa
On 9/28/11 10:23 AM, NeilBrown wrote:
[...]Quoted 3 lines
Quoted 2 lines
Then I used fdisk to change the partition type to Linux raid auto
Quoted 9 lines
Quoted 5 lines
You can do that if you like but it will have no effect. The "raid auto"
partition type only means anything on MBR partitions. You don't need to, so
don't bother.Thanks Neil.
Not using fdisk worked like a charm.Quoted 6 lines
Using fdisk probably resulted in the disks going over to MBR rather than GPT, and thus you have a 2TB limit.
By the way, you should probably try the parted again and fix the alignment issue (rather than just "ignoring" it) - it will make a /big/ difference.
Quoted 7 lines
In terms of speed?
This RAID array is temporarily just so I can back up/restore my broken 5x2TB RAID6 but it would be interesting to know what to do. I was running# parted -a optimal /dev/sdd which was suppose to fix that warning but it didn't.
Quoted 8 lines
Yes, I was thinking in terms of speed. I haven't gone beyond 2 TB disks with MBR myself, so I can't comment on whether your partitions really are misaligned, or if it is just an incorrect warning. But if these disks are like most 2 TB disks with 4K sectors but which lie and claim to have 512 byte sectors (for compatibility with ancient and inferior OS'es), then partition misalignment will be major performance hit. It's worth double-checking that you've got it right here, before you go to far with the array.
These are 3TB Hitachi drives and Hitachi kept 512 byte sectors:
http://www.hitachigst.com/internal-drives/desktop/deskstar/deskstar-7k3000
Signature · 1 line
Marcin M. Jessa
Quoted 45 lines · Marcin M. Jessa
Quoted 35 lines · David Brown
Quoted 26 lines · Marcin M. Jessa
Quoted 17 lines · David Brown
Quoted 6 lines · Marcin M. Jessa
On 9/28/11 10:23 AM, NeilBrown wrote:
[...]Quoted 3 lines
Quoted 2 lines
Then I used fdisk to change the partition type to Linux raid auto
Quoted 9 lines
Quoted 5 lines
You can do that if you like but it will have no effect. The "raid auto"
partition type only means anything on MBR partitions. You don't need to, so
don't bother.Thanks Neil.
Not using fdisk worked like a charm.Quoted 7 lines
Using fdisk probably resulted in the disks going over to MBR rather than
GPT, and thus you have a 2TB limit.By the way, you should probably try the parted again and fix the alignment issue (rather than just "ignoring" it) - it will make a /big/ difference.
Quoted 7 lines
In terms of speed?
This RAID array is temporarily just so I can back up/restore my broken 5x2TB RAID6 but it would be interesting to know what to do. I was running# parted -a optimal /dev/sdd which was suppose to fix that warning but it didn't.Quoted 8 lines
Yes, I was thinking in terms of speed. I haven't gone beyond 2 TB disks with MBR myself, so I can't comment on whether your partitions really are misaligned, or if it is just an incorrect warning. But if these disks are like most 2 TB disks with 4K sectors but which lie and claim to have 512 byte sectors (for compatibility with ancient and inferior OS'es), then partition misalignment will be major performance hit. It's worth double-checking that you've got it right here, before you go to far with the array.
Quoted 3 lines
These are 3TB Hitachi drives and Hitachi kept 512 byte sectors:
http://www.hitachigst.com/internal-drives/desktop/deskstar/deskstar-7k3000
I did not know such drives existed - I thought all 2TB+ drives were 4K sector size. If these drives really have 512 byte sectors, then alignment will not be an issue.
Quoted 19 lines · Marcin M. Jessa
# parted /dev/sde GNU Parted 2.3 Using /dev/sde Welcome to GNU Parted! Type 'help' to view a list of commands. (parted) mklabel gpt Warning: The existing disk label on /dev/sde will be destroyed and all data on this disk will be lost. Do you want to continue? Yes/No? yes (parted) mkpart primary 0 -0 Warning: The resulting partition is not properly aligned for best performance. Ignore/Cancel? ignore (parted) print Model: ATA Hitachi HDS72303 (scsi) Disk /dev/sde: 3001GB Sector size (logical/physical): 512B/512B Partition Table: gpt
Quoted 5 lines
Number Start End Size File system Name Flags
1 17.4kB 3001GB 3001GB primary(parted) quit
I run into something similar working with 2Terabytes disks. I had to use % instead o sizes.
Eg:
(parted) mkpart
Partition name? []? 1
File system type? [ext2]?
Start? 0
End? 100%
(parted) set 1
Flag to Invert? raid
New state? [on]/off? on
I think the "primary" concept is for DOS 3.3 partition tables and might not apply here. Please, correct if I am wrong.
THanks
Sebastian
Quoted 6 lines · Marcin M. Jessa
# parted /dev/sde GNU Parted 2.3 Using /dev/sde Welcome to GNU Parted! Type 'help' to view a list of commands.
Try with gdisk instead, I find it much more command friendly than parted.