Replace HDD for ZFS pool. need help!

Status
Not open for further replies.

fuyun1965

Dabbler
Joined
Jul 25, 2011
Messages
17
I have a Freenas 8.0 box, with 3x2T HDD at raidz for a ZFS pool. One drive fail, need to be replaced. I replace a new HDD, and do some zpool command to attache the new HDD into the pool, make it online, something like that (I forgot what I did). But cann't replace the bad HDD with the new one. The situation is:
freenas_err_02.jpg

freenas_err_01.jpg


Am I added the new ada0 into the pool wrong? Can I take it out of the pool? I should have made snapshot image before doing the above replacement job. Any help for that? What should I do now?
Need help!

Regards,
Chan
 

Knowltey

Patron
Joined
Jul 21, 2013
Messages
430
A snapshot wouldn't have helped you in this situation anyhow, those are for data recovery on properly functioning pools. If you lose your pool or accidentally misconfigure it a snapshot won't fix that.
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
You should have followed the manual for replacing a failed disk. At this point you need to get another disk to replace the failed disk in the RAIDZ1 plus another disk to put your ada0 in a mirrored vdev. As it stands, if ada0 fails you will lose your entire pool.

I'd highly recommend you get familiar with the manual because your mistakes could have been prevented by following the manual.
 

fuyun1965

Dabbler
Joined
Jul 25, 2011
Messages
17
Thanks, cyberjock,
At this point, can I take out the ada0 from the pool? If can't, then I plan to reform the pool, may you suggest me a solution?
Can I do this?
1. Due to my data in the pool is about 1.8T, I add a new 2T HDD into the box, and form a pool2
2. Then copy the data from the old pool into the temp pool2.
3. then remove the old pool, and reform a new pool in ZFS raidz with three HDDs.
4. restore data from the temp pool2 to the new ZFS pool.
5. remove the temp pool2.

Any way to do the pool to pool copy fast?

Thsnks again!
Chan
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
Those steps seem like the best option. Go with a RAIDZ2 instead of a RAIDZ1. I just posted a few minutes ago to someones thread where they're losing data because they made the bad choice to go with a RAIDZ1. That link in my signature warning about RAIDZ1 isn't there as a joke. It's there because of how many people have lost data.

The fastest way I can think of to do a pool to pool copy is to use the cp command locally at the machine to copy the files. Google "manpage cp" to see how to use it. Your command will be something like "cp -R /mnt/oldpool /mnt/newtemppool"
 

fuyun1965

Dabbler
Joined
Jul 25, 2011
Messages
17
Thanks for your response.
Do you suggest me to build another freenas box for the temp pool with single disc? or put the HDD into the old machine? I do have a ready machine right now. I have gigabit network. And due the old machine, my pool read write speed not so fast, only 40MB/s. no different with through network.
 
Status
Not open for further replies.
Top