How to make FreeNAS forget about an export'd ZFS volume?

Status
Not open for further replies.

TimHenrion

Cadet
Joined
Nov 1, 2011
Messages
3
FreeNAS 8.02 on an HP N40L w/8GM RAM.

I was testing out a single disk ZFS volume on an external USB drive attached to my FreeNAS system. That ZFS volume was created properly and shared as an AFP share. All good.

Then I wanted to test something else and went to export the volume so that I could re-purpose the disk. I clicked on the Export Volume button. The usual export dialog came up except that it had a "remove all shares using this volume" because AFP was still on and this volume was shared.

So I ensure that "destroy data" and "remove all shares" were both check. I clicked the "OK" button and the WebGUI hung. 5 minutes later I killed the browser.

In the GUI, both the ZFS volume and the AFP share were gone as expected. Unfortunately the "Alert" light in the upper right hand corner started blinking yellow. When I clicked it, an alert came up that said "WARNING: The volume Test (ZFS) status is".

'zpool status' shows the ZFS volume as gone but FreeNAS thinks its still there. Can anyone tell me how I get FreeNAS to forget about that ZFS volume?
 

tha_toadman

Dabbler
Joined
Jun 5, 2011
Messages
16
I too need to know how this is done as I've exported a volume and FreeNAS is still alerting me about it after its removal from the system.
 

tha_toadman

Dabbler
Joined
Jun 5, 2011
Messages
16
Here's mine:

Disabled|Always On|{uuid}646e8c55-0e23-11e1-9a0b-6c626d704570|1|Disabled|Auto|Member of disk250 stripe|1||1|ada0
Disabled|Always On|{uuid}ef0373b3-0e23-11e1-9a0b-6c626d704570|1|Disabled|Auto|Member of disk500 stripe|2||2|ada1
Disabled|Always On|{uuid}08e85f1d-0e24-11e1-9a0b-6c626d704570|1|Disabled|Auto|Member of disk750 stripe|3||3|ada2

disk500 (ada1) was exported/deleted from my system as the drive was going bad. So technically it should even be in there anymore.
 

ProtoSD

MVP
Joined
Jul 1, 2011
Messages
3,348
There's another command that you probably missed in the CODE box if you scrolled down, can you post that also?

sqlite3 /data/freenas-v1.db "select * from storage_diskgroup;"

EDIT: and this one also:
sqlite3 /data/freenas-v1.db "select * from storage_volume;"
 

tha_toadman

Dabbler
Joined
Jun 5, 2011
Messages
16
1|disk250stripe|stripe|1
2|disk500stripe|stripe|2
3|disk750stripe|stripe|3

and

1|disk250|ZFS
2|disk500|ZFS
3|disk750|ZFS

Respectively
 

ProtoSD

MVP
Joined
Jul 1, 2011
Messages
3,348
Ok, first we need to backup your database, and then fix the database. From the command line with root privileges do:

1) mount -uw /
2) cp /data/freenas-v1.db /data/freenas-v1.db.bak
3) sqlite3 /data/freenas-v1.db "delete from storage_disk where id=2;"
4) sqlite3 /data/freenas-v1.db "delete from storage_diskgroup where id=2;"
5) sqlite3 /data/freenas-v1.db "delete from storage_volume where id=2;"
6) reboot

If you experience problems after rebooting, mount -uw / and copy freenas-v1.db.bak to freenas-v1.db and reboot.
 
Status
Not open for further replies.
Top