Page 1 of 1

Problem creating partition

Posted: 2010/04/15 20:18:38
by fugtruck
Here is the scoop. I had 3 drives in a RAID-5 array, partitioned as such:
Disk /dev/sda: 438.4 GB, 438489317376 bytes
255 heads, 63 sectors/track, 53309 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 35220 282800227+ 83 Linux
/dev/sda3 35221 35475 2048287+ 82 Linux swap
/dev/sda4 35476 35539 514080 5 Extended
/dev/sda5 35476 35539 514048+ 83 Linux

I added a disk to the array and now need to partition the free space. If I try to use fdisk, I get an error, "No free sectors available". So I tried using parted. Here is what it shows as the partition table:
Disk geometry for /dev/sda: 0.000-418176.000 megabytes
Disk label type: msdos
Minor Start End Type Filesystem Flags
1 0.031 101.975 primary ext3 boot
2 101.975 276274.072 primary ext3
3 276274.072 278274.353 primary linux-swap
4 278274.353 278776.384 extended
5 278274.384 278776.384 logical ext3
I used the 'mkpart' command, specifying a logical partition of file system type ext3 with a start of 278776.384 and an end of some number higher than this but lower than 418176. When I do this, I get an error, "Unable to satisfy all constraints on the partition". Can anyone tell me what I am doing wrong?
[Moderator edit: Added code tags to preserve formatting.]

Re: Problem creating partition

Posted: 2010/04/15 21:33:45
by fugtruck
I think I figured out what I need to do. I need to resize the extended partition to include all the free space, then I should be able to add additional locgical partitions. Does that sound about right?

Re: Problem creating partition

Posted: 2010/04/16 21:05:09
by pschaff
Sounds like a hardware RAID question from reading between the lines. No hardware RAID controller I have used would allow expanding an existing array by just adding a drive, but YMMV. Hard to guess with no info about the hardware, and not really a CentOS question.

If you do manage to add space to the array without destroying it, then a new partition could presumably be created within the extended partition, formatted and mounted, or added to an existing LVM volume group, and a logical volume expanded.

Re: Problem creating partition

Posted: 2010/04/19 18:43:19
by fugtruck
Thanks for the response. It is a hardware RAID and I was able to expand it. The RAID controller is a Dell PERC 5/i, which does allow for expanding arrays, which went without a hitch.

Eventually, I was able to add partitions by first expanding the size of the extended array. Then I was able to add additional logical partitions.

Fyi, in the past I've been able to expand hardware arrays on HP ProLiant servers with HP's RAID controllers.