Date: Mon, 10 Mar 2014 21:13:03 +1300 From: Jonathan Chen <jonc@chen.org.nz> To: Johan Hendriks <joh.hendriks@gmail.com> Cc: FreeBSD <freebsd-questions@freebsd.org> Subject: Re: How to destroy a zpool that can no longer be imported? Message-ID: <CAJuc1zOHKvv-T5fhCuszOFdm_2SWKCo5HgOnbgzCkpCiWmxFAw@mail.gmail.com> In-Reply-To: <531D7114.2030803@gmail.com> References: <CAJuc1zO92Qgfr5gcy2peU2yi8nipzOsdqDekhAJ54ofo2p=Ppg@mail.gmail.com> <531D7114.2030803@gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On 10 March 2014 21:00, Johan Hendriks <joh.hendriks@gmail.com> wrote: > Jonathan Chen schreef: > >> Hi, >> >> While experimenting ZFS, I've ended up with a zpool that can't be >> imported: >> >> 8:41pm# zpool import >> pool: lake >> id: 10528535549827216272 >> state: UNAVAIL >> status: One or more devices are missing from the system. >> action: The pool cannot be imported. Attach the missing >> devices and try again. >> see: http://illumos.org/msg/ZFS-8000-3C >> config: >> >> lake UNAVAIL insufficient replicas >> 12490607842175990247 UNAVAIL cannot open >> >> I don't care about the (non-existent) data, but I would like to remove >> the pool entry. The standard way is to import the pool and then >> destory it. However, this pool cannot be import (even with -f) and so >> there doesn't seem to be a way to destroy it. >> >> How do I get rid of this bogus faulted pool? > > > Try zpool labelclear, it will wipe the labels from the disk. > > Be aware that zpool labelclear clears all labels like gimmor, gpart and not > only zpool labels so you will end up with a clean disk !!!! Yeah. I've already tried this: ,9:03pm# zpool labelclear -f 12490607842175990247 Unable to open 12490607842175990247 The pool used to be on ada1, but: ,9:04pm# zpool labelclear -f ada1 Unable to open ada1 Hmm. I looked at /var/log/messages and noticed: Mar 10 20:44:56 osiris kernel: ZFS WARNING: Unable to attach to diskid/DISK-VFK201R2FDB0BX. Mar 10 20:44:57 osiris kernel: ZFS WARNING: Unable to attach to ada1. 9:10pm# zpool labelclear -f /dev/diskid/DISK-VFK201R2FDB0BX 9:10pm# zpool import 9:10pm# Thanks for pointing me in the right direction! Cheers. -- Jonathan Chen <jonc@chen.org.nz>
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAJuc1zOHKvv-T5fhCuszOFdm_2SWKCo5HgOnbgzCkpCiWmxFAw>