I have a pool named test_pool and i can only see it when "zfs import" is run. How can i delete this pool and detach associated device from it ?
# zpool import
pool: test_pool
id: 13538020891587345121
state: FAULTED
status: One or more devices contains corrupted data.
action: The pool cannot be imported due to damaged devices or data.
The pool may be active on another system, but can be imported using
the '-f' flag.
see: http://zfsonlinux.org/msg/ZFS-8000-5E
config:
data_pool FAULTED corrupted data
raidz1-1 ONLINE
sdf UNAVAIL corrupted data
sdg UNAVAIL corrupted data
sdh UNAVAIL corrupted data
I have tried # zpool import test_pool -f
to import and get it destroyed but get below message
cannot import 'data_pool': one or more devices is currently unavailable
If the pool is not imported, just go ahead and wipe the data on the actual block devices. This will in essence wipe the pool.
You don't have to wipe the whole device - just the metadata is enough.
You should see something like the below:
If you do see output with only
zfs_member
and theUUID
to match on each line, then you got the right device - go ahead and wipe them out:After that,
zpool import
should not find any pools to import.P.S. You can use the same method to destroy any kind of device - software raid, DRBD, filesystem, etc.