Raid1 replaced with raid10?
Hi,
I just tried an idea I got after fiddling with raid10 and to my dismay it worked as I thought it will. I used two small partitions on separate disks to create a raid1 array. Then I did dd if=/dev/md2 of=/dev/null. I got only one of the disks reading. Nothing unexpected. Then I created a raid10 array on the same two partitions with the options -l10 -n2 -pf2. The same dd executed at twice the speed, reading _simultaneously_ from both drives. I did some bonnie++ benchmarking - same result - raid1 reads only from a single disk raid10 from both. Write performance is worse (about 10% slower) with raid10, but you get twice the read speed. In this light the obvious question is: can raid10 be used as a drop-in replacement for raid1 or there is a caveat with having the amount of disks equal the amount of chunk copies?
Peter
Hi,
I asked this question back in march but received no answers, so here it goes again. Is it safe to replace raid1 with raid10 where the amount of disks is equal to the amount of far/near/offset copies? I understand it has the downside of not being a bit-by-bit mirror of a plain filesystem. Are there any other caveats?
Thanks
Peter
Quoted 8 lines · Peter Rabbitson
Hi,
I asked this question back in march but received no answers, so here it goes again. Is it safe to replace raid1 with raid10 where the amount of disks is equal to the amount of far/near/offset copies? I understand it has the downside of not being a bit-by-bit mirror of a plain filesystem. Are there any other caveats?
Clearly you have reduced capacity, since there's a mirror AND a CRC, otherwise I don't see any drawbacks. The performance should be much better.
Signature · 3 lines
bill davidsen <[email protected]> CTO TMR Associates, Inc Doing interesting things with small computers since 1979
Quoted 11 lines · On Friday May 4, [email protected] wrote:
Quoted 8 lines · Peter Rabbitson
Hi,
I asked this question back in march but received no answers, so here it goes again. Is it safe to replace raid1 with raid10 where the amount of disks is equal to the amount of far/near/offset copies? I understand it has the downside of not being a bit-by-bit mirror of a plain filesystem. Are there any other caveats?
Clearly you have reduced capacity, since there's a mirror AND a CRC, otherwise I don't see any drawbacks. The performance should be much better.
CRC ??? md/raid10 doesn't have any CRC.
What CRC are you thinking of?
To answer the original question, I assume you mean "replace" as in "backup, create new array, then restore".
You will get different performance characteristics. Whether they better suit your needs or not will depend largely on your needs.
NeilBrown
Quoted 11 lines · Neil Brown
Quoted 9 lines · On Friday May 4, [email protected] wrote:
Quoted 8 lines · Peter Rabbitson
Hi,
I asked this question back in march but received no answers, so here it goes again. Is it safe to replace raid1 with raid10 where the amount of disks is equal to the amount of far/near/offset copies? I understand it has the downside of not being a bit-by-bit mirror of a plain filesystem. Are there any other caveats?
Quoted 4 lines
To answer the original question, I assume you mean "replace" as in "backup, create new array, then restore".
You will get different performance characteristics. Whether they better suit your needs or not will depend largely on your needs.
Hi Neil,
Yes I meant take an existing 2 drive raid1 array (non bootable data) and put a raid10 array in its place. All my testing indicates that I get the same write performance but nearly double the read speed (due to interleaving I guess). It seemed to good to be true, thus I am asking the question. Could you elaborate on your last sentence? Are there downsides I could not think of? Thank you!
Peter
Quoted 17 lines · On Monday May 7, [email protected] wrote:
Quoted 11 lines · Neil Brown
Quoted 9 lines · On Friday May 4, [email protected] wrote:
Quoted 8 lines · Peter Rabbitson
Hi,
I asked this question back in march but received no answers, so here it goes again. Is it safe to replace raid1 with raid10 where the amount of disks is equal to the amount of far/near/offset copies? I understand it has the downside of not being a bit-by-bit mirror of a plain filesystem. Are there any other caveats?
Quoted 4 lines
To answer the original question, I assume you mean "replace" as in "backup, create new array, then restore".
You will get different performance characteristics. Whether they better suit your needs or not will depend largely on your needs.
Quoted 7 lines
Hi Neil,
Yes I meant take an existing 2 drive raid1 array (non bootable data) and put a raid10 array in its place. All my testing indicates that I get the same write performance but nearly double the read speed (due to interleaving I guess). It seemed to good to be true, thus I am asking the question. Could you elaborate on your last sentence? Are there downsides I could not think of? Thank you!
I would have thought that you need "far" or "offset" to improve read performance, and they tend to hurt write performance (though I haven't really measured "offset" much).
What layout are you using?
NeilBrown
Quoted 24 lines · Neil Brown
Quoted 15 lines · On Monday May 7, [email protected] wrote:
Quoted 10 lines · Neil Brown
Quoted 9 lines · On Friday May 4, [email protected] wrote:
Quoted 8 lines · Peter Rabbitson
Hi,
I asked this question back in march but received no answers, so here it goes again. Is it safe to replace raid1 with raid10 where the amount of disks is equal to the amount of far/near/offset copies? I understand it has the downside of not being a bit-by-bit mirror of a plain filesystem. Are there any other caveats?
Quoted 4 lines
To answer the original question, I assume you mean "replace" as in "backup, create new array, then restore".
You will get different performance characteristics. Whether they better suit your needs or not will depend largely on your needs.Quoted 7 lines
Hi Neil,
Yes I meant take an existing 2 drive raid1 array (non bootable data) and put a raid10 array in its place. All my testing indicates that I get the same write performance but nearly double the read speed (due to interleaving I guess). It seemed to good to be true, thus I am asking the question. Could you elaborate on your last sentence? Are there downsides I could not think of? Thank you!
Quoted 6 lines
I would have thought that you need "far" or "offset" to improve read performance, and they tend to hurt write performance (though I haven't really measured "offset" much).
What layout are you using?
Correct, I am using 'far' layout. The interleaving of the 'offset' layout does not work too good for sequential reads, but far really shines. Yes write performance is hurt by about 10%. Compared to 190% gain in reads I can live with it.
Quoted 13 lines · Neil Brown
Quoted 11 lines · On Friday May 4, [email protected] wrote:
Quoted 9 lines · Peter Rabbitson
Hi,
I asked this question back in march but received no answers, so here it goes again. Is it safe to replace raid1 with raid10 where the amount of disks is equal to the amount of far/near/offset copies? I understand it has the downside of not being a bit-by-bit mirror of a plain filesystem. Are there any other caveats?
Quoted 6 lines
Quoted 2 lines
Clearly you have reduced capacity, since there's a mirror AND a CRC, otherwise I don't see any drawbacks. The performance should be much better.
CRC ??? md/raid10 doesn't have any CRC.
What CRC are you thinking of?
There is an entire paragraph missing here, no doubt a finger check due to trying to post and get out to lunch. I was rambling on about raid6, mirroring 1+5, and other things which never made it. The post can be scrubbed, I was just rambling on at length about various other solutions possible.
Not worth a repost, since I was way over answering his question...
Quoted 8 lines
To answer the original question, I assume you mean "replace" as in "backup, create new array, then restore".
You will get different performance characteristics. Whether they better suit your needs or not will depend largely on your needs.NeilBrown
Signature · 3 lines
bill davidsen <[email protected]> CTO TMR Associates, Inc Doing interesting things with small computers since 1979
Quoted 1 line · Bill Davidsen
Not worth a repost, since I was way over answering his question...
Erm... and now you made me curios :) Please share your thoughts if it is not too much trouble. Thank you for your time.
Peter