Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 20 Jul 2007 15:07:16 +0200
From:      Alexander Leidinger <Alexander@Leidinger.net>
To:        Ulf Lilleengen <lulf@FreeBSD.org>
Cc:        perforce@freebsd.org, Eric Anderson <anderson@freebsd.org>
Subject:   Re: PERFORCE change 123662 for review
Message-ID:  <20070720150716.77d2636a@deskjail>
In-Reply-To: <20070720123524.GA71360@twoflower.idi.ntnu.no>
References:  <200707172109.l6HL9PMJ078780@repoman.freebsd.org> <46A03390.3030602@freebsd.org> <20070720123524.GA71360@twoflower.idi.ntnu.no>

next in thread | previous in thread | raw e-mail | index | archive | help
Quoting Ulf Lilleengen <lulf@FreeBSD.org> (Fri, 20 Jul 2007 14:35:24 +0200):

[growing RAID-5]
> Well, what I do is to attach/create the new subdisk as usual, but since it's a
> RAID-5 array that I know is operational, I give the subdisk a flag, and sets the
> plex in a resize state. Then, In the raid-5 code, I modify gv_raid5_offset
> (which basically computes offsets within a subdisk based on the number of
> subdisks and stripesize). However, what I do, is that instead of taking all
> subdisks in the calculation, I only take those who does not have the GROW flag
> (when reading), and I take all subdisks into calculation when it's a write.
> 
> This means, that if a create a gv_grow_plex function that reads (stripesize x
> sdcount) bytes (from the subdisks that do not have the GROW flag), and writes
> that data to the plex (including all subdisks). This way, i sort of overwrite
> the old data, but the data is spread out over the new subdisks. I'm sorry if
> this might seem a bit complex, but just ask more questions if you didn't
> understand.

Do you use the additional drive(s) only to write checksums to them, or
do you write real data to it? If the later, how do you make sure you
read the right data in case you read data again, which was just written
there a moment before (how do you know to read from all subdisks and
not only from a subset in this case)?

Bye,
Alexander.

-- 
TONY RANDALL!  Is YOUR life a PATIO of FUN??
http://www.Leidinger.net  Alexander @ Leidinger.net: PGP ID = B0063FE7
http://www.FreeBSD.org     netchild @ FreeBSD.org  : PGP ID = 72077137



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20070720150716.77d2636a>