I was just wondering what would happen in a raidz array if one of the drives failed? I imagine everything would work fine for reading, but will I be able to write to the array still? If I can write, does that mean that replacing the dead drive with a working one will catch up the new drive? I think this is where resilvering comes in, how long would it take to ''catch up''? And finally, if this is the case, is it possible to make an array with 3 drives, and then add the mirror later? I imagine this is extremely similar to the previous situation. I ask because I have 4 drives, but one of them has data on it at the moment that I''d need to put into the array before I can add the data to the array. This message posted from opensolaris.org
On Wed, 30 Jul 2008, Vanja wrote:> > And finally, if this is the case, is it possible to make an array > with 3 drives, and then add the mirror later? I imagine this is > extremely similar to the previous situation.One of the joys of using mirrors is that you can add a mirror device, and you can later take it away. Adding a mirror device causes it to be resilvered from the existing data drive(s). This means you can convert a non-redundant load-shared configuration into a redundant load-shared configuration. If you are desperate for a drive, you can remove one from a mirror. Bob =====================================Bob Friesenhahn bfriesen at simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/ GraphicsMagick Maintainer, http://www.GraphicsMagick.org/
On Wed, Jul 30, 2008 at 07:24, Vanja <vanjab at gmail.com> wrote:> I was just wondering what would happen in a raidz array if one of the drives failed? I imagine everything would work fine for reading, but will I be able to write to the array still?Yes.> If I can write, does that mean that replacing the dead drive with a working one will catch up the new drive? I think this is where resilvering comes in, how long would it take to ''catch up''?It depends on how much data is on the drives; ZFS only resilvers as much data is present on disk, not necessarily the whole disk.> And finally, if this is the case, is it possible to make an array with 3 drives, and then add the mirror later? I imagine this is extremely similar to the previous situation.Do you mean "add the parity later"? If so, this might be possible, but it''s not recommended. Back up your data elsewhere and then restore it onto the array. You need a backup anyways, so now is a perfect time to make one. Will
Sorry I meant "add the parity drive". I''ve got too much data to keep secondary backups, for now. This message posted from opensolaris.org
>This means you can convert a non-redundant load-shared configuration into aredundant>load-shared configuration.Bob, Does that imply that when you add zfs automatically load-balances across its mirrors? Does that also mean that when the drives in a mirror are not as fast as each other, the fs speed will not be hindered by the slower drive? justin -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/x-pkcs7-signature Size: 3361 bytes Desc: not available URL: <http://mail.opensolaris.org/pipermail/zfs-discuss/attachments/20080730/9e673458/attachment.bin>
Vanja <vanjab <at> gmail.com> writes:> > And finally, if this is the case, is it possible to make an array with > 3 drives, and then add the mirror later?I assume you are asking if it is possible to create a temporary 3-way raidz, then transfer your data to it, then convert it to a 4-way raidz ? No it is not possible. However here is one solution (let''s call your 4 drives A, B, C and D -- your current data is on D). 1. Slice up A, B, C in 2 halves each: A1 and A2, B1 and B2, C1 and C2. 2. Create a 3-way raidz on A2, B2 and C2. 3. Copy your data from D to the 3-way raidz. 4. Slice up D in 2 halves: D1 and D2. 5. Create a 4-way raidz on A1, B1, C1, D1. 6. Copy your data from the 3-way raidz to the 4-way raidz. 7. Destroy the A2, B2, C2, D2 slices. 8. Grow A1, B1, C1, D1 to extend over the remaining disk space. 9. Export and reimport the 4-way raidz to make it register the extra space. Yes that''s a lot of steps. But that''s also the safest solution as your data would never transit on a (temporarily) degraded raidz (as it is possible for example on Linux by creating a raid5 MD with one "missing" component). -marc
On Wed, 30 Jul 2008, Justin Vassallo wrote:> > Does that imply that when you add zfs automatically load-balances across its > mirrors?Yes, ZFS load balances across mirrors. If you add individual drives to a ZFS pool, it will load-share across the drives. You can then add mirrors for those drives and now you have load-share plus redundancy. In addition to redundancy, a read can be done from either drive so there is more read performance.> Does that also mean that when the drives in a mirror are not as fast as each > other, the fs speed will not be hindered by the slower drive?It is my understanding that the write speed to a pair will ultimately be limited by the speed of the slowest drive so you should try to make sure that the drives in a mirror are similar. It may be that zfs is willing to buffer data if a drive in a mirror pair is slow since it has the smarts to catch it up later. Bob =====================================Bob Friesenhahn bfriesen at simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/ GraphicsMagick Maintainer, http://www.GraphicsMagick.org/