Bug 193965

Summary: [zfs] zpool coredump on import
Product: Base System Reporter: will
Component: kernAssignee: freebsd-fs (Nobody) <fs>
Status: New ---    
Severity: Affects Only Me CC: smh
Priority: ---    
Version: 10.2-STABLE   
Hardware: Any   
OS: Any   

Description will 2014-09-27 06:06:32 UTC
I had a pool with 3 mirrors, a single floating disk in a RAID-0 and an SSD that was both a cache and a log device. I got a new drive, and wanted to mirror the single disk (bringing me up to four mirrors) and remove the SSD.

I booted normally and did a zpool remove tank gpt/log and zpool remove tank gpt/cache. I powered off to install the hard disk. I booted with the new disk attached and the SSD detached, and the machine kernel panicked. I removed the disk and reattached the SSD as normal, and the machine panicked again. I removed both the new disk and the SSD, and the machine still panicked.

I booted into mfsbsd (10, still). I did a zpool import -R /a tank (after a mkdir /a, of course). This caused a coredump in zpool (see https://imgur.com/25yAdon). The coredump is available here: http://kefka.worrbase.com/zpool.core

Finally, I did a zpool import -F -n -R /a tank, and the pool imported successfully.
Comment 1 will 2014-09-29 05:37:09 UTC
It's worth noting that even after getting the pool imported on mfsbsd, adding the new drive and resilvering, thens shuttind down gracefully, my 10.0-STABLE OS on the zpool itself still fails to import.
Comment 2 will 2014-10-08 00:55:20 UTC
My kernel panics on boot were resolved after re-adding the cache and logging devices. Does this mean that it's not safe to remove a log device on ZFS on root?
Comment 3 Steven Hartland freebsd_committer freebsd_triage 2015-03-15 11:59:53 UTC
Please try with stable/10 and if still unsuccessfully current to see if this is already fixed as 10.0-RELEASE is pretty old now.
Comment 4 will 2015-11-15 16:41:02 UTC
Hey,

I know this is a fairly old bug, but I was able to reproduce it on 10.2-STABLE by removing the log device and rebooting. I'll try and produce some more dumps or a patch today.