Problem importing old 1 drive zpool

Status
Not open for further replies.

Husky

Dabbler
Joined
Oct 16, 2014
Messages
10
I just tried to grab some data from an old 1 drive zfs pool that was not in use for about a year. It however doesn't work. Does anybody have an idea how to access the pool? I think the device was named different in the old machine.

Code:
[root@freenas] ~# zpool import
   pool: harddisk
     id: 11245568988528280564
  state: UNAVAIL
status: The pool was last accessed by another system.
action: The pool cannot be imported due to damaged devices or data.
   see: http://illumos.org/msg/ZFS-8000-EY
config:

        harddisk     UNAVAIL  missing device
          ada0p2     ONLINE


Code:
[root@freenas] ~# zpool import harddisk
cannot import 'harddisk': pool may be in use from other system, it was last accessed by freenas.local (hostid: 0x47307aed) on Fri Mar 15 03:01:18 2013
use '-f' to import anyway


Code:
[root@freenas] ~# zpool import -f harddisk
cannot import 'harddisk': one or more devices is currently unavailable




I thought it might be a missing log device but providing "-m" doesn't help:


Code:
[root@freenas] ~# zpool import -f -m harddisk
cannot import 'harddisk': one or more devices is currently unavailable




Additional info that might help to track down the issue

Code:
[root@freenas] ~# zdb -l /dev/gptid/7df89392-fc09-11e0-a869-003005c4d551
--------------------------------------------
LABEL 0
--------------------------------------------
    version: 15
    name: 'harddisk'
    state: 0
    txg: 201310
    pool_guid: 11245568988528280564
    hostid: 1194359533
    hostname: 'freenas.local'
    top_guid: 117745139941842
    guid: 117745139941842
    vdev_tree:
        type: 'disk'
        id: 1
        guid: 117745139941842
        path: '/dev/da2p2'
        whole_disk: 0
        metaslab_array: 23
        metaslab_shift: 33
        ashift: 9
        asize: 1498149552128
        is_log: 0
        DTL: 427
--------------------------------------------
LABEL 1
--------------------------------------------
    version: 15
    name: 'harddisk'
    state: 0
    txg: 201310
    pool_guid: 11245568988528280564
    hostid: 1194359533
    hostname: 'freenas.local'
    top_guid: 117745139941842
    guid: 117745139941842
    vdev_tree:
        type: 'disk'
        id: 1
        guid: 117745139941842
        path: '/dev/da2p2'
        whole_disk: 0
        metaslab_array: 23
        metaslab_shift: 33
        ashift: 9
        asize: 1498149552128
        is_log: 0
        DTL: 427
--------------------------------------------
LABEL 2
--------------------------------------------
    version: 15
    name: 'harddisk'
    state: 0
    txg: 201310
    pool_guid: 11245568988528280564
    hostid: 1194359533
    hostname: 'freenas.local'
    top_guid: 117745139941842
    guid: 117745139941842
    vdev_tree:
        type: 'disk'
        id: 1
        guid: 117745139941842
        path: '/dev/da2p2'
        whole_disk: 0
        metaslab_array: 23
        metaslab_shift: 33
        ashift: 9
        asize: 1498149552128
        is_log: 0
        DTL: 427
--------------------------------------------
LABEL 3
--------------------------------------------
    version: 15
    name: 'harddisk'
    state: 0
    txg: 201310
    pool_guid: 11245568988528280564
    hostid: 1194359533
    hostname: 'freenas.local'
    top_guid: 117745139941842
    guid: 117745139941842
    vdev_tree:
        type: 'disk'
        id: 1
        guid: 117745139941842
        path: '/dev/da2p2'
        whole_disk: 0
        metaslab_array: 23
        metaslab_shift: 33
        ashift: 9
        asize: 1498149552128
        is_log: 0
        DTL: 427
 
Last edited:

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
What OS was the drive created under? Was it FreeNAS 8+?
 

Husky

Dabbler
Joined
Oct 16, 2014
Messages
10
I am not 100% sure but i think so (ZFS V15 as detected by the last commands also indicates that).

I already tried to import with 8.3 but it didn't work either.

Edit: Oh I just realised that 8.3 already had V28 - will try again with 8.2
 
Last edited:

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
How about the output of "zdb -eC <poolname>" .

The output will need to be in pastebin, the forums will garble the output.
 

Husky

Dabbler
Joined
Oct 16, 2014
Messages
10
it says "device not configured" when i run this command

Btw. zpool import on freenas 8.2 says "insufficient replicas" for the pool while the single disk is still shown "online".
 
Last edited:

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
Try the zdb command I listed above with 9.2.1.8. There really is no reason to use the old FreeNAS versions at this point. Anything the old versions can do the new versions should be able to do.
 

Husky

Dabbler
Joined
Oct 16, 2014
Messages
10
Roger that - reinstalling the new version - will report back in a few minutes
 

Husky

Dabbler
Joined
Oct 16, 2014
Messages
10
Code:
[root@freenas] ~# zdb -eC harddisk
zdb: can't open 'harddisk': No such file or directory


The following commands shows sth, tho


Code:
[root@freenas] ~# zdb -e harddisk

Configuration for import:
        version: 15
        pool_guid: 11245568988528280564
        name: 'harddisk'
        state: 0
        hostid: 1194359533
        hostname: 'freenas.local'
        vdev_tree:
            type: 'root'
            id: 0
            guid: 11245568988528280564
            children[0]:
                type: 'missing'
                id: 0
                guid: 0
            children[1]:
                type: 'disk'
                id: 1
                guid: 117745139941842
                whole_disk: 0
                metaslab_array: 23
                metaslab_shift: 33
                ashift: 9
                asize: 1498149552128
                is_log: 0
                DTL: 427
                path: '/dev/ada0p2'
zdb: can't open 'harddisk': No such file or directory
 
Last edited:

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
Yeah, sounds like one of two things has happened:

1. The pool got corrupted and is giving output for commands that are incorrect for conditions.
2. The pool was not a single disk pool.

I'm leaning *heavily* towards #2. In particular, because it says a device is missing. I'm going to guess that you had more disks and you don't remember having more than 1 disk.

In any case, without all of the children to make the pool whole you won't be able to get access to the pool again. It was clearly made on FreeNAS and was v15.
 

Husky

Dabbler
Joined
Oct 16, 2014
Messages
10
I am 100% sure that it was a single disk pool. I think it might be the slog device that is missing. I am running zpool import -m -fFX harddisk atm. and at least it's doing something - dunno if it will be successfull thi
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
If you had an slog, you are screwed. Versions of ZFS that are below v19 (which yours is) won't mount without the slog.
 

Husky

Dabbler
Joined
Oct 16, 2014
Messages
10
Is there a way to access the data without mounting the zpool? Like a forensics script or sth. The data is very important (it was a vmdk file).
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
Is there a way to access the data without mounting the zpool? Like a forensics script or sth. The data is very important (it was a vmdk file).

Nope. The way to access the data is to mount the pool. No recovery tools for ZFS exist, which is mentioned on slide 11 of my noobie presentation. This is why using ZFS with sufficient redundancy and performing scrubs at regular intervals is crucial. If your zpool gets corrupted you'll lose your data forever.

If recovery is worth a 5-digit cost, give a company like Ontrack a call. But I'm serious when I say 5-digit. They will change you the cost of a mid-sized sedan because they know they have you by the balls. The one person I know of that actually did recovery with a company like ontrack paid $17k for 450GB of data. ;)
 
Status
Not open for further replies.
Top