I have tried to import my pool using a variety of commands, however it always fails. This is after a clean reboot. I did hot-add a number of disks to the server and then subsequently used them to create the pool, and this is the first reboot since creating the pool, not sure if there is a relationship. Unfortunately there is some data on the pool which is not backed up and needs to be recovered if at all possible.

If i specify the device name, as in

sudo zpool import -d /dev/disk/by-id/ neo
sudo zpool import neo

I get

cannot import 'neo': one or more devices are already in use

If I instead just run sudo zpool import, I get

   pool: neo
     id: 5358137548497119707
  state: UNAVAIL
 status: One or more devices contains corrupted data.
 action: The pool cannot be imported due to damaged devices or data.
    see: http://zfsonlinux.org/msg/ZFS-8000-5E

    neo                                                   UNAVAIL  insufficient replicas
      raidz3-0                                            UNAVAIL  insufficient replicas
        ata-HGST_HMS5C4040ALE640_PL1331LAHGWAJH-part1     ONLINE
        ata-Hitachi_HDS5C4040ALE630_PL2331LAGD00RJ-part1  UNAVAIL
        ata-ST4000DM000-1F2168_Z301VKAC-part1             UNAVAIL
        ata-HGST_HMS5C4040ALE640_PL1331LAHGSVDH-part1     ONLINE
        ata-Hitachi_HDS5C4040ALE630_PL1331LAGD81AH-part1  UNAVAIL
        ata-WDC_WD40EFRX-68WT0N0_WD-WCC4EPFK6PYP-part1    UNAVAIL
        ata-WDC_WD40EFRX-68WT0N0_WD-WCC4EK2CU8SV-part1    UNAVAIL
        ata-Hitachi_HDS5C4040ALE630_PL2331LAGD08UJ-part1  UNAVAIL
        ata-HGST_HMS5C4040ALE640_PL1331LAHD0BNH-part1     ONLINE
        ata-HGST_HMS5C4040ALE640_PL1331LAHGXGSH-part1     ONLINE
        ata-HGST_HMS5C4040ALE640_PL1331LAHGXG6H-part1     ONLINE
        ata-HGST_HMS5C4040ALE640_PL1331LAHGW0DH-part1     ONLINE

However, ALL OF THESE DEVICES ARE PRESENT (e.g. I did a ls -l and there are symlinks for all of the UNAVAIL devices), and the few UNAVAILs I just checked with smartctl report healthy).

Considering I ended up in this state during a clean reboot (sudo shutdown -r now), I'm really hoping there is a way to recover the data. Any help would be greatly appreciated.

Thank you, Eric


I should have paid more attention to the error message that "one or more devices are already in use". It turns out that a number of these drives were previously part of a mdadm array (many thanks Matt Sieker), so the kernel was stealing those drives away from ZFS before ZFS could attempt to import. Guess I'm going to be removing those drives from the array one by one, zeroing the mdadm superblocks, and then reimporting.

cat /proc/mdstat
Personalities : [linear] [multipath] [raid0] [raid1] [raid6] [raid5] [raid4] [raid10]
md3 : inactive sde1[1](S) sdb1[6](S) sdh1[0](S) sdg1[2](S) sdf1[5](S)
      19534432357 blocks super 1.2

md127 : inactive sdc1[6](S)
      2930134471 blocks super 1.2
| improve this answer | |
  • Holy PANTS, I've been having this exact issue for AGES, and it's so obvious in retrospect. Arrrrrggghhh. – Fake Name Sep 14 '18 at 4:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.