geom raid5 module

Ulf Lilleengen lulf at stud.ntnu.no
Thu Dec 14 15:05:51 PST 2006


On ons, des 13, 2006 at 10:45:14am +0100, Olivier Cochard-Labbe wrote:
> Here is, for example, the first problem problem with geom vinum RAID5:
> 
> I have 4 disks:
> - ad0: 203MB
> - ad1: 101MB
> - ad2: 306MB
> - ad3: 101MB
> 
> If I create a raid 5 volume with these disk, can you confirme that the
> theorical size should be 300MB (4 disks of the smallest drive: 100MB)
> ? It's the size given with graid5 and with RAID caclulator
> (http://dorm.tunkeymicket.com/raidcalc/).
> But with geom vinum I obtain a 611MB disk:
> 

Hi,

I found the "bug"! The thing is that gvinum sets the plex-size after the last
subdisk created instead of the smallest. I started to make a fix to make it set
it to the lowest, but then I began thinking. You should not make different-sized
subdisks in a raid5 configuration.

Then I discovered this is "fixed" in CURRENT, by giving you an error when you
try to create a raid5 volume with different-sized subdisks. And I think this
makes sense. If you create a raid5-volume, all subdisks should be the same size.

However, I'm thinking of maybe make gvinum be more "autodetectable" on this upon
creation by actually examining which subdisk is smallest when you give it a 
raid5 plex with different-sized subdisks.

I'll look more into your second problem tomorrow :)

-- 
Ulf Lilleengen


More information about the freebsd-geom mailing list