Failed drive remains after replace

Status
Not open for further replies.

M H

Explorer
Joined
Sep 16, 2013
Messages
98
Would anyone have some insight as to how to remove the ghost entry from my ZFS pool? I used the replace command and it successfully resilvered the drive, but the only failed drive entry still remains.

pool: data
state: DEGRADED
scan: scrub in progress since Mon Sep 16 15:23:31 2013
116G scanned out of 507G at 74.3M/s, 1h30m to go
0 repaired, 22.80% done
config:

NAME STATE READ WRITE CKSUM
data DEGRADED 0 0 0
mirror-0 DEGRADED 0 0 0
ada1p2 ONLINE 0 0 0
replacing-1 DEGRADED 0 0 0
10476183271550833829 UNAVAIL 0 0 0 was /dev/gptid/d3cd2f62-8aff-11e1-a870-0019b934cd58
ada0 ONLINE 0 0 0

errors: No known data errors

Thanks!
 

Dusan

Guru
Joined
Jan 29, 2013
Messages
1,165
There should be a Detach button on the Volume Status screen (it only appears after you select a disk).
 

M H

Explorer
Joined
Sep 16, 2013
Messages
98
The resilvering DID complete and I manually ran a ZFS scrub. The phantom disk does not appear anywhere in the WebGUI, only when running a zpool status.
 

M H

Explorer
Joined
Sep 16, 2013
Messages
98
Hvala in lep pozdrav!
 

Dusan

Guru
Joined
Jan 29, 2013
Messages
1,165
This is strange. The Volume Status screen shows the result of zpool status, so you should see the same disks.
Are you sure you really checked the Volume Status? It is the screen where you clicked the Replace button. Actually, looking at your zpool status it seems you did not use the FreeNAS GUI disk replace functionality at all-- ada0 is missing the swap partition. Go here: Storage / Volumes / View Volumes / [click on the pool] / Volume Status button (below the volumes, looks like a sheet of paper)
(I do not speak Slovenian. :) )
 

M H

Explorer
Joined
Sep 16, 2013
Messages
98
Sorry, Dusan is my brother's name so I assumed.

Anyway, once the drive failed, there was no record of it anywhere in the GUI. Even after I removed it and replaced with new, there was no drive listed to detach. It was only shown in zpool status. The I did zpool replace old ID and ada number of new drive. Silvering completed so I ran scrub like the data shown. Do I need to create cache? I don't remember there being a cache partition.
 

Dusan

Guru
Joined
Jan 29, 2013
Messages
1,165
FreeNAS creates a 2GB swap partition on a drive by default. That's why the other vdev in your pool is ada1p2 -- second partition on ada1, ada1p1 is the swap partition. It's not 100% necessary, but it's there to protect you in case you run out of physical memory.
I know I repeat myself, but this screen basically directly shows the output of zpool status:
Status1b.png

Replace1e.png

After you physically remove the drive (while it is still part of a pool), it will not show anywhere else in the GUI, only on this screen: Storage / Volumes / View Volumes / [click on the pool] / Volume Status button (below the volumes, looks like a sheet of paper). Can you post a screenshot of what you see there? You can always run zpool detach [pool] [device] from the CLI, but I would like to check what's going on -- if zpool status shows the drive, it also must show on the Volume Status screen.
(yes, a Slavic given name, but I'm Slovak, not Slovenian :) )
 

M H

Explorer
Joined
Sep 16, 2013
Messages
98
My apologies for the confusion regarding your name. I looked briefly and thought it said Slovenia instead of Slovakia.

I'm cannot access the machine again until tomorrow. I will post a screenshot for you. Thank you again for your attention to my problem. How would I go about restoring the swap partition?
 

Dusan

Guru
Joined
Jan 29, 2013
Messages
1,165
You would have to detach the drive from the pool. Partition it to include a swap and a zfs partition and resilver it back into the pool. However, you would be back to no redundancy during the operation, so I'm not sure it's worth it.
 

M H

Explorer
Joined
Sep 16, 2013
Messages
98
Ok great thank you. I do have an RSYNC task that backs up all data to an external drive weekly, so I can update that before removing the drive. I will post again tomorrow when I'm trying to fix the mess I made. Again, I can't thank you enough for your help.
 

M H

Explorer
Joined
Sep 16, 2013
Messages
98
You were right! It did show there under Volume Status. I don't know how I missed that option. Thank you!!

Now I would like to recreate the swap partition, I only have the option to offline. So I would offline and then detach. Then create the two partitions and used replace on the ada0p2 partition?
 

M H

Explorer
Joined
Sep 16, 2013
Messages
98
Actually, when I click replace on ada0, it gives me the option of an in-place replacement with ada0. Would this work also?

Thanks.
 

Dusan

Guru
Joined
Jan 29, 2013
Messages
1,165
I just tried that in a VM and the in-place replace will fail as ZFS will refuse to use a drive that is a part of an active pool.
This seems to work in a VM:
  1. Offline the drive on the Volume status screen
  2. Use the quick wipe on the View disks screen
  3. Use the replace functionality on the Volume status screen (this will also create the swap partition)
For future, I really recommend reading the documentation: Replacing a Failed Drive or SSD
It describes the correct steps to replace a failed disk and it would save you all these troubles...
 

M H

Explorer
Joined
Sep 16, 2013
Messages
98
Thank you so much Dusan. It's funny, I did read those instructions first, but was frustrated once I could not find the drive in the GUI and decided to go the CLI route. You have certainly helped me regain my bearings.
 

M H

Explorer
Joined
Sep 16, 2013
Messages
98
I followed the instructions above. The replace failed with the following error:
Sep 23 10:52:08 PAEDNAS manage.py: [middleware.exceptions:38] [MiddlewareError: Disk replacement failed: "cannot open 'gptid/b81713d2-245f-11e3-87b2-90b11c79c2b7': no such GEOM provider, must be a full path or shorthand device name, "]
 

Dusan

Guru
Joined
Jan 29, 2013
Messages
1,165
Hmm. Did you wipe the drive? What is the output of: zpool status and gpart show ?
 

M H

Explorer
Joined
Sep 16, 2013
Messages
98
Luckily, before failing there, I did repartition the replacement drive. So I just did a zpool replace to ada0p2 this time and it is resilvering as we speak. Thanks.
 

M H

Explorer
Joined
Sep 16, 2013
Messages
98
I did quick wipe the drive.
 

M H

Explorer
Joined
Sep 16, 2013
Messages
98
pool: data
state: DEGRADED
status: One or more devices is currently being resilvered. The pool will
continue to function, possibly in a degraded state.
action: Wait for the resilver to complete.
scan: resilver in progress since Mon Sep 23 11:15:37 2013
7.02G scanned out of 458G at 4.72M/s, 27h9m to go
7.01G resilvered, 1.53% done
config:

NAME STATE READ WRITE CKSUM
data DEGRADED 0 0 0
mirror-0 DEGRADED 0 0 0
ada1p2 ONLINE 0 0 0
replacing-1 OFFLINE 0 0 0
4930134376841983996 OFFLINE 0 0 0 was /dev/ada0
ada0p2 ONLINE 0 0 0 (resilvering)

errors: No known data errors
 
Status
Not open for further replies.
Top