Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Oracle and Raid setup
"VC" <boston103_at_hotmail.com> wrote:
> Hi,
>
> <xhoster_at_gmail.com> wrote in message
> news:20050609141630.752$66_at_newsreader.com...
> > Frank van Bortel <frank.van.bortel_at_gmail.com> wrote:
> [... skipped ...]
>
> >> Why would a mirrored write be slower for writes? OK, as slow
> >> as the slowest disk, but those differences can (should!) only
> >> be marginal.
> >
> > If each write takes a random amount of time uniformly distributed
> > between 0 and 1 (in whatever units of time would make sense), then the
> > average wait for one write is 0.5, while the average wait for slower of
> > two
> > writes is 0.6667.
>
> I wonder how you arrived at the number (0.6667)...
Probability and calculus. By definition of uniform 0 to 1, Pr(rand<=x)=x. since they are independent Pr(max(rand1,rand2)<=x) = x^2. Convert cdf to pdf by differentiation gives pdf(max=x)=2x. The average is integration x*dx*pdf(x) over 0 to 1 which is integration 2x^2 which is 2/3x^3|0to1, which gives 2/3.
And then I simulated it in Excel, just to be sure.
> Let's assume that track seeks are distributed uniformly (each track,
> from a given position, is accessed with the same probability).
I had thought rotational waits were dominant over head-seek waits these days.
> Further,
> let's assume we have two *identical* disks. Then, the seek distance is
> a random variable Xr = min(X1, X2) for reads and Xw=max(X1,X2) for
> writes. Then, with another huge assumption of X1 and X2 being
> independent, it can be shown that the expected seek distance would be
> approx. 0.2*n for reads and 0.46*n where n is the number of tracks. For
> a single disk, both values are n/3. So, for reads we would have about
> 39% gain in performance and for writes about 38% loss.
You could be more explicit in the "it can be shown" part, but that's good enough for me.
Xho
-- -------------------- http://NewsReader.Com/ -------------------- Usenet Newsgroup Service $9.95/Month 30GBReceived on Sun Jun 12 2005 - 14:39:21 CDT