Honest mistake

Status
Not open for further replies.

Rene Raggl

Cadet
Joined
Feb 21, 2017
Messages
5
Good evening everybody!

As stated in my introduction, I have been skimming these forums for 2+ years and always found helpful information.

However, now I made a mistake and apparently nobody was yet so dumb to make exactly the same. At least I could not finding anything matching my dilemma exactly, which is the following:

I recently bought an older enterprise grade server (see specs below) to up my game on FreeNAS and introduce redundancy in my system, which had a single point of failure with only one data drive in the even older ThinkCentre M57 I was using for this purpose previously.

I store all my movies, music, pictures and documents on my FreeNAS. While it is nothing I could not live without, it would be very unfortunate to lose any of this.

To cut a long story short: I recently got my 2nd 2 TB drive and wanted to use it to mirror the first 2TB drive (RAID1 style), so that if either of the two drives fails, there would still be a backup. I was following one guide on the net, but what I ended up with is a striped volume that is 4 TB.

I am at a point where I don't dare to proceed on my own anymore as I am scared of data loss: how can I take the second drive off the volume without damaging it and then reintroduce it to the system as a mirror drive?

I only have those two 2 TB drives at the moment (+2x 160GB, currently not mounted in the system) and money is an issue, so - at least right now - I can't just splurge for two more.

Running FreeNAS 9.10.2
 
Last edited by a moderator:

bigphil

Patron
Joined
Jan 30, 2014
Messages
486
How much space have you used on your striped pool? Your safest bet is to copy the data to another drive or pool, wipe out the original striped pool, re-create it as a proper mirrored pool and copy the data back.
 

Rene Raggl

Cadet
Joined
Feb 21, 2017
Messages
5
I thought of that too, but I am actually looking for some way around that, because currently I use approximately 600 Gigabytes, which makes it just an awkward thing to deal with:

I have no drives that could hold that data while correcting the issue. I do have an external 500 GB drive which is currently hooked up to my HTPC, but that just does not cut it.
I could potentially try to divide the data between that drive and whatever space is left available on my laptop, but that entails quite a risk of something going wrong while separating and later merging the data again.
 

bigphil

Patron
Joined
Jan 30, 2014
Messages
486
You have more risk doing it any other way. 600GB is not a lot of data. The safest and easiest way to do it would be to source an 1TB+ drive (two would be very safe as you could create a temp mirrored pool), create a new pool in the same FreeNAS box and perform an internal replication to it (zfs send/recv). If you cant find any spare drives that are big enough to do this, I don't know what to tell you. Using any other method like trying to convert your stripe to a mirror is just asking for trouble and puts you at even greater risk.
 

Arwen

MVP
Joined
May 17, 2014
Messages
3,611
TL;DNR
Backup, (multiple if possible), destroy the pool and re-create it as Mirror.


At present, there is no way to remove a ZFS vDev.

Each disk of a ZFS striped pool is considered a vDev, (virtual device). This is the holy grail
of ZFS, being able to remove a vDev. Mostly for EXACTLY the reason you have, a mistake,
(Zpool "add" instead of the proper "attach").

FreeNAS 10 is expected to have a little more safety features to prevent this kind of thing.
Though to be fair, FreeNAS was never intended to be everything to everyone, super easy
and beyond user friendly. We like it because it uses ZFS, currrently the best file system around
for data integrity.
 

Stux

MVP
Joined
Jun 2, 2016
Messages
4,419
There is no way to remove the second vdev.

Your options are to backup, rebuild and restore, which might involve buying another HD.

Or to buy two more HDs, and add a mirror to each stripe (correctly this time!)

Sorry :(
 

Stux

MVP
Joined
Jun 2, 2016
Messages
4,419
There is no way to remove the second vdev.

Your options are to backup, rebuild and restore, which might involve buying another HD.

Or to buy two more HDs, and add a mirror to each stripe (correctly this time!)

Sorry :(

Perhaps you have a buddy you can borrow a drive from?
 

Rene Raggl

Cadet
Joined
Feb 21, 2017
Messages
5
Thank you guys for your answers! Well, then I am basically screwed: I went way over budget as it is with this build and upgrading it.

If I do it, I want to do it properly, so will add another 2x2TB and mirror the first stripe, which I guess is the safest option. So I am back where I started with a single point of failure and will have to wait until I have saved enough to buy the other two drives. Crossing my fingers that neither of the other two don't crap out on me in the meantime...

@Arwen: Wow, if that is TLDNR for you...
 

Rene Raggl

Cadet
Joined
Feb 21, 2017
Messages
5
Perhaps you have a buddy you can borrow a drive from?
None of my buddies is a big a nerd as I am... ;)
As a matter of fact, none of them even has a spare drive (except thumb drives :().
 

Stux

MVP
Joined
Jun 2, 2016
Messages
4,419
The fault is the FreeNAS 9 GUI which doesn't allow converting a stripe to a mirror, where as ZFS command line does.

When it's time to fix it, be sure to ask for help :)

It's non-trivial.
 

Arwen

MVP
Joined
May 17, 2014
Messages
3,611
...
@Arwen: Wow, if that is TLDNR for you...
It was not just for you. This issue comes up about every 3 or 4 months. So I wanted something reasonably
clear for others who search for this issue. Basically ZFS has some gotchas, some are slowly going away,
(the famous dataset destroy hanging your pool is no longer relevant with asynchronous dataset destroy...).
 
Last edited:

Robert Trevellyan

Pony Wrangler
Joined
May 16, 2014
Messages
3,778
will add another 2x2TB and mirror the first stripe
I just want to make sure you understand the situation. You can't "mirror a stripe" (unless that stripe is a single disk). What you will be able to do, if you obtain two more 2TB drives, is to mirror each of your existing drives, turning your pool into a striped pair of 2 x 2TB mirrors. But you won't be able to do this using the GUI.
 

spg900ny

Dabbler
Joined
Feb 10, 2012
Messages
28
However, now I made a mistake and apparently nobody was yet so dumb to make exactly the same.

All due respect, you're not uniquely dumb. lol

I did the exact same thing with an almost full 4TB drive. Wanted to mirror it, ended up making one big stripe. So now, instead of the benefit of redundancy, I had made things significantly worse by spreading a stripe over two large drives.

I ended up buying another 4TB drive (which IIRC was about $200 at the time - ouch - which I didn't really have) and copied all the data over, then mirrored. Only benefit was I was then able to toss a few 1TB drives that had data I didn't mind losing and consolidate onto the extra 4TB drive.

One little click caused so much trouble. Believe me, I was a lot more careful when doing volume management after that. :O
 

wblock

Documentation Engineer
Joined
Nov 14, 2014
Messages
1,506
The fault is the FreeNAS 9 GUI which doesn't allow converting a stripe to a mirror, where as ZFS command line does.

When it's time to fix it, be sure to ask for help :)

It's non-trivial.
Wait, how? Do you mean by adding another stripe as a mirror of the first? Because if there is an in-place stripe to mirror converter, that would be very surprising.
 

Stux

MVP
Joined
Jun 2, 2016
Messages
4,419
Last edited:

wblock

Documentation Engineer
Joined
Nov 14, 2014
Messages
1,506
But that is merely adding another drive to a single-drive stripe. That is not a big deal. Show me an in-place conversion of a two-drive stripe (the kind that people use by mistake) into a mirror, and I'll be very impressed.
 

Stux

MVP
Joined
Jun 2, 2016
Messages
4,419
A two drive stripe is just two drives in a pool. Turn one into a mirror and then the other

There is no way to remove the second vdev.

Your options are to backup, rebuild and restore, which might involve buying another HD.

Or to buy two more HDs, and add a mirror to each stripe (correctly this time!)
 

JJT211

Patron
Joined
Jul 4, 2014
Messages
323
Ive made this same mistake as well but it only cost me a $20 restocking fee.

Just purchase a new drive, copy data over, make new mirror properly, copy data back, secure wipe new drive (took several days as it was a 6TB drive, but doable), return to store and pay restocking fee.
 

wblock

Documentation Engineer
Joined
Nov 14, 2014
Messages
1,506
A two drive stripe is just two drives in a pool. Turn one into a mirror and then the other
What I mean by "in-place" is being able to convert a two-drive stripe to a mirror without losing the data on the stripe when one drive is removed.
 

Stux

MVP
Joined
Jun 2, 2016
Messages
4,419
Well, no. It's a 2 vdev pool at that stage

But the GUI doesn't allow you to 'convert' a vdev stripe to a mirror by adding another drive, and it should since this is a feature of ZFS. And in fact the boot drive ui does support it
 
Status
Not open for further replies.
Top