How to remove orphaned drive from view disks?

Status
Not open for further replies.

Brian Blater

Dabbler
Joined
Dec 17, 2014
Messages
41
Hi everyone,

I've been using FreeNAS for a while now and slowly getting the hang of things. I'm getting ready to remove 4 old drives from the system and add some new larger drives and had a question.

A little while ago I had to replace a failed drive in my system. If I looked in "view disks" it was associated with da2. Well, as I'm getting ready to add new drives, I noticed that da2 still shows up in view disks (with no serial number) and at the shell the system doesn't see anything at /dev/da2. So, I'm wondering how to delete this "orphaned" entry in view disks. Did a bunch of searches and didn't find anything specific other than someone talked about deleting it through the /var/db/collectd/rrd/localhost/ entries. No real specific information was given, so I didn't want to try anything that could potentially crash the whole thing.

So, I come to the forums hoping to find out how to do this, especially since I'm getting ready to replace four more drives and don't want to see those listed in view disks after they are gone.

Can someone let me know what needs to be done or point me to someplace that shows this? I couldn't seem to find anything in the forums either, but that may be just the key words I used.

This is: FreeNAS-9.3-STABLE-201412300101

Thanks,
Brian
 
Last edited:

mav@

iXsystems
iXsystems
Joined
Sep 29, 2011
Messages
1,428
Possibly there could be other reasons for disk to not disappear, but the most typical is that disk hot-removed without detaching it through the WebUI first. After that it's remnants remain in system due to still open swap partition. There is only one solution for that -- system reboot. It should become less dirty after recently committed improvements, but it is still better to detach disks before removal.
 

Brian Blater

Dabbler
Joined
Dec 17, 2014
Messages
41
Possibly there could be other reasons for disk to not disappear, but the most typical is that disk hot-removed without detaching it through the WebUI first. After that it's remnants remain in system due to still open swap partition. There is only one solution for that -- system reboot. It should become less dirty after recently committed improvements, but it is still better to detach disks before removal.

Ok, let me look at this "detach" operation. I followed the instructions for removing a failed drive, so not sure why it is still there.
 

Brian Blater

Dabbler
Joined
Dec 17, 2014
Messages
41
So, I didn't find anything for detaching other than the normal procedures for replacing a failed drive. So, looking at reports etc, this may just be a reboot needed.
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
No, you actually forgot to perform the last step of the disk replacement procedure. ;)

You aren't the first to not follow the procedure from beginning to end, and you certainly won't be the last.
 

Lastb0isct

Explorer
Joined
Jun 15, 2011
Messages
96
No, you actually forgot to perform the last step of the disk replacement procedure. ;)

You aren't the first to not follow the procedure from beginning to end, and you certainly won't be the last.
What is that step because I'm not seeing anything else that needs to be done...

"If the disk is formatted with ZFS, click the disk’s entry then its “Offline” button in order to change that disk’s status to OFFLINE. This step is needed to properly remove the device from the ZFS pool and to prevent swap issues. If your hardware supports hot-pluggable disks, click the disk’s “Offline” button, pull the disk, then skip to step 3. If there is no “Offline” button but only a “Replace” button, then the disk is already offlined and you can safely skip this step."
"Once the resilver is complete, “Volume Status” will show a “Completed” resilver status and indicate if there were any errors. Figure 8.1q indicates that the disk replacement was successful for this example."

Those are the instructions i followed as mine was already in "Offline" state i just needed to replace the drive. My old drive is still listed in the View Disk menu as well. I shouldn't require a reboot as i've done this several times in the past. This is my first drive replacement since 9.3 upgrade though.
 
Status
Not open for further replies.
Top