[FreeBSD 6.0-RELEASE] Incorrect geometry for VIA RAID0 array

Jason Harmening jason.harmening at gmail.com
Fri Dec 9 07:57:44 PST 2005


Yes, the array is being recognized properly.  The problem seems to be in the
via_read_meta() function in sys/dev/ata/ata_raid.c.  Essentially, the
problem is that in the case of a striped array, the function overwrites the
total sector count of the top-level raid descriptor with the sector count of
each enumerated disk, rather than adding to the sector count.  Last night I
installed FreeBSD on the first half of the array, and then built a custom
kernel with a modification to fix this issue.  The full 148G capacity of the
array is now recognized, and I've been able to expand my slice with fdisk
and bsdlabel/newfs a new partition in the added space. So far I've written
about a gig of data to the new partition, and everything is working fine.

Note that even if you had a striped array, you wouldn't see this issue
because in your case the OS would use the promise_read_meta() routine, which
doesn't have this bug.


On 12/8/05, greg byshenk <gbyshenk at byshenk.demon.nl> wrote:
>
> On freebsd-stable, jason.harmening at gmail.com (Jason Harmening) wrote:
>
> >  Here's the dmesg output from the installer:
>
> >  ad4: 70911MB <WDC WD740GD-00FLA1 27.08D27> at ata2-master SATA150
> >  ad6: 70911MB <WDC WD740GD-00FLC0 33.08F33> at ata3-master SATA150
> >  ar0: 70911MB <VIA Tech V-RAID RAID0 (stripe 64 KB)> status: READY
> >  ar0: disk0 READY using ad4 at ata2-master
> >  ar0: disk1 READY using ad6 at ata3-master
>
> Are you _sure_ that the array is being recognized properly?
>
> Based on the dmesg output, it looks like the controller is being read
> as a 74G drive.
>
> FWIW, this is the section of my dmesg output, for a _mirror_:
>
>   ad4: 78167MB <Maxtor 6Y080P0 YAR41BW0> at ata2-master UDMA133
>   ad6: 78167MB <Maxtor 6Y080P0 YAR41BW0> at ata3-master UDMA133
>   ar0: 77247MB <Promise Fasttrak RAID1> status: READY
>   ar0: disk0 READY (master) using ad4 at ata2-master
>   ar0: disk1 READY (mirror) using ad6 at ata3-master
>
>
> >  On 12/7/05, Jason Harmening <jason.harmening at gmail.com> wrote:
>
> > > I'm trying to install FreeBSD 6.0-RELEASE on a RAID0 array attached to
> the
> > > VIA 8237 controller on my Asus A8V Deluxe motherboard.  The array
> consists
> > > of two 74G drives.  The installer recognizes the array as ar0, but
> when I
> > > enter FDISK to set up my partition, the size of the array is only
> recognized
> > > as 74G, rather than the true 148G.  I've double-checked all my BIOS
> > > settings, and nothing seems out of order.  Please help!
>
>
> --
> greg byshenk  -  gbyshenk at byshenk.net  -  Leiden, NL
>


More information about the freebsd-stable mailing list