How to remove a device /disk from zpool where there is no redundancy

Status
Not open for further replies.

p jensen

Cadet
Joined
Jun 5, 2017
Messages
1
I accidentally added a disk to a zpool the wrong way in the process of replacing a bad disk. Now I can't remove the disk because it is listed as a device with no redundancy. How do I remove da2? Using zpool remove pdx-zfs-02 da2 doesn't work. It returns "cannot remove da2: only inactive hot spares, cache, top-level, or log devices can be removed". Zfs in freebsd/freenas doesn't allow the removal of devices that don't have redundancy. There are not force options. How can I work around this?

NAME STATE READ WRITE CKSUM
pdx-zfs-02 DEGRADED 0 0 0
raidz2-0 DEGRADED 0 0 0
gptid/c459110a-a73c-1a49-b12c-f03fbec6eca6 FAULTED 158 25.3K 0 too many errors
gptid/8c87e988-7832-1e44-9c45-abe95ee2d8f7 ONLINE 0 0 0
gptid/3b4be4d0-136e-41e3-c546-d5c4ba2b3142 ONLINE 0 0 0
gptid/209e8c9c-ff66-6f6a-e38b-9045c0b6c3ec ONLINE 0 0 0
gptid/ea8b834a-0692-464b-fd29-a877bf8f7bb9 ONLINE 0 0 0
gptid/cf35d740-ea0b-bae6-9e4f-b7a31d66ab1d ONLINE 0 0 0
gptid/fe908e73-c93b-72ed-d4bb-9eae78bcc5b6 ONLINE 0 0 0
gptid/bdf03e4d-ba71-a4cc-dd90-edfd6446bac3 ONLINE 0 0 0
gptid/302bacc1-273a-54c9-c8f9-f458640b0d60 ONLINE 0 0 0
gptid/d94ea326-d5aa-f062-9662-953908ce0b53 ONLINE 0 0 0
raidz2-1 ONLINE 0 0 0
gptid/3c1b1d3b-3977-11e6-b1f0-0025902b035a ONLINE 0 0 0
gptid/3ec0ba4a-3977-11e6-b1f0-0025902b035a ONLINE 0 0 0
gptid/40d8b781-3977-11e6-b1f0-0025902b035a ONLINE 0 0 0
gptid/43387eae-3977-11e6-b1f0-0025902b035a ONLINE 0 0 0
gptid/45800439-3977-11e6-b1f0-0025902b035a ONLINE 0 0 0
gptid/47df2694-3977-11e6-b1f0-0025902b035a ONLINE 0 0 0
da2 ONLINE 0 0 0
 

Dice

Wizard
Joined
Dec 11, 2015
Messages
1,410
How can I work around this?
Unfortunately there is no other workaround than destroying the pool, reconfiguring raidz2's followed by a restore data from backup process.
Classic mistake, I hope I never accidentally do it myself :/
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
I accidentally added a disk to a zpool the wrong way in the process of replacing a bad disk.
So how exactly did you do that? You blew through a warning that looks like this:
Screen Shot 2017-06-05 at 5.12.09 PM.png

...and then went to Manual setup, and then added the disk. Didn't anything about that suggest that you might be doing it wrong?
 

Dice

Wizard
Joined
Dec 11, 2015
Messages
1,410
@danb35 can I haz bigger picture stating the point a little bit closer to my nose plz? :P :P :P
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
Well, the picture size was just what my screen shot did. But I'll admit, the post was a little snarky. At the same time, though, I'm genuinely mystified how people continue to blow through this. We have a good, clear, through manual. It has clear, correct, step-by-step instructions on replacing a disk. Nowhere do those instructions say to go anywhere near the Volume Manager. But people do, over and over again, and ignore the warning that's in bold red print, and then come here asking how to fix it. I just don't get it.

Edit: linky
 

Stux

MVP
Joined
Jun 2, 2016
Messages
4,419
In the meantime, you could add another drive to the non-redundant stripe to make it a mirror, and restore redundancy to your pool, until you work out how you're going to back it up so you can recreate it and restore.
 

Jailer

Not strong, but bad
Joined
Sep 12, 2014
Messages
4,977

Ericloewe

Server Wrangler
Moderator
Joined
Feb 15, 2014
Messages
20,194
We need to make users type "I accept that this is irreversible and carries significant risk of data loss and does nothing to replace a drive."
 
Status
Not open for further replies.
Top