Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kernel Oops at zfs_prop_get_type in zcommon #4337

Closed
pluser opened this issue Feb 15, 2016 · 2 comments
Closed

Kernel Oops at zfs_prop_get_type in zcommon #4337

pluser opened this issue Feb 15, 2016 · 2 comments

Comments

@pluser
Copy link

pluser commented Feb 15, 2016

When I issue zpool import, zpool command returns a message as if the pool was normal.

saturn ~ # zpool import
   pool: zpool
     id: 1358522578922881949
  state: ONLINE
 status: The pool is formatted using a legacy on-disk version.
 action: The pool can be imported using its name or numeric identifier, though
        some features will not be available without an explicit 'zpool upgrade'.
 config:

        zpool       ONLINE
          mirror-0  ONLINE
            sdi     ONLINE
            sda1    ONLINE

But, when I issue zpool import zpool, the command freeze and kernel print an error message.

saturn ~ # zpool import zpool # Freeze!
saturn ~ # dmesg
[   95.284909] BUG: unable to handle kernel paging request at 0000004fa00f3abc
[   95.284957] IP: [<ffffffffa00ee2fe>] zfs_prop_get_type+0xe/0x20 [zcommon]
[   95.284997] PGD 32a20d067 PUD 0
[   95.285018] Oops: 0000 [#1] SMP
[   95.285039] Modules linked in: zfs(PO) zunicode(PO) zcommon(PO) znvpair(PO) spl(O) zavl(PO) snd_hda_codec_hdmi amdgpu snd_hda_codec_generic snd_hda_intel snd_hda_codec snd_hwdep snd_hda_core snd_pcm snd_timer snd amdkfd radeon kvm_amd kvm drm_kms_helper syscopyarea sysfillrect sysimgblt soundcore irqbypass efivars psmouse atkbd libps2 serio_raw k10temp fam15h_power evdev fb_sys_fops ttm drm efivarfs
[   95.285280] CPU: 2 PID: 4065 Comm: dump_list_strat Tainted: P        W  O    4.4.0-gentoo-r1 #2
[   95.285321] Hardware name: Gigabyte Technology Co., Ltd. To be filled by O.E.M./F2A88X-D3H, BIOS F6 04/09/2015
[   95.285367] task: ffff88006b743000 ti: ffff880327358000 task.ti: ffff880327358000
[   95.285402] RIP: 0010:[<ffffffffa00ee2fe>]  [<ffffffffa00ee2fe>] zfs_prop_get_type+0xe/0x20 [zcommon]
[   95.285449] RSP: 0018:ffff88032735b6d8  EFLAGS: 00010212
[   95.285474] RAX: 0000004fffffffb0 RBX: ffff88032735b870 RCX: 0000000000000000
[   95.285507] RDX: 0000000000000000 RSI: 0000000000000000 RDI: 00000000ffffffff
[   95.285540] RBP: ffff88032735b6d8 R08: ffff88033ed16d60 R09: ffff880330f10fa0
[   95.285573] R10: ffff88033ed16e40 R11: ffffea000ca0be00 R12: 0000000000000010
[   95.285606] R13: 00000000ffffffff R14: ffff88032735b870 R15: ffff88032735b9a8
[   95.285666] FS:  00007fded2957780(0000) GS:ffff88033ed00000(0000) knlGS:0000000000000000
[   95.285696] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[   95.285718] CR2: 0000004fa00f3abc CR3: 000000032a0b8000 CR4: 00000000000406e0
[   95.285744] Stack:
[   95.285753]  ffff88032735b998 ffffffffa061d66f ffff88032f9ded00 0000000000000003
[   95.285787]  ffff88032a232000 ffff88032735b9a8 ffff880330f10ca0 ffff880330f10fa0
[   95.285821]  ffffffffa00f1c42 ffff88032a232000 ffff8803278ae800 ffff88032b384300
[   95.285854] Call Trace:
[   95.285880]  [<ffffffffa061d66f>] dsl_prop_inherit+0x66f/0x9c0 [zfs]
[   95.285910]  [<ffffffffa05e87cd>] ? arc_buf_eviction_needed+0x7d/0xc0 [zfs]
[   95.285942]  [<ffffffffa05edaf2>] ? dbuf_rele_and_unlock+0x2a2/0x4a0 [zfs]
[   95.285976]  [<ffffffffa05f9194>] ? dmu_object_info_from_dnode+0x74/0xd0 [zfs]
[   95.286008]  [<ffffffffa05edd21>] ? dbuf_rele+0x31/0x40 [zfs]
[   95.286034]  [<ffffffff8115f6ff>] ? __kmalloc_node+0x1af/0x1e0
[   95.286058]  [<ffffffffa027390f>] ? spl_kmem_alloc+0xbf/0x160 [spl]
[   95.286084]  [<ffffffffa00efa30>] ? zprop_string_to_index+0x100/0x170 [zcommon]
[   95.286112]  [<ffffffffa02736e5>] ? spl_kmem_free+0x25/0x40 [spl]
[   95.286136]  [<ffffffffa00ef83b>] ? zprop_iter_common+0xbb/0x110 [zcommon]
[   95.286163]  [<ffffffff8115f6ff>] ? __kmalloc_node+0x1af/0x1e0
[   95.286187]  [<ffffffffa0273bd9>] ? spl_kmem_alloc_impl+0xc9/0x170 [spl]
[   95.286213]  [<ffffffffa0273bd9>] ? spl_kmem_alloc_impl+0xc9/0x170 [spl]
[   95.286240]  [<ffffffffa0275a64>] ? spl_vmem_alloc+0x14/0x20 [spl]
[   95.286265]  [<ffffffffa010c24a>] ? fnvlist_remove_nvpair+0x8a/0x1c2 [znvpair]
[   95.286294]  [<ffffffffa0107655>] ? nvlist_remove_nvpair+0x85/0x190 [znvpair]
[   95.286323]  [<ffffffff8165fadd>] ? mutex_lock+0xd/0x2a
[   95.286353]  [<ffffffffa061d91d>] dsl_prop_inherit+0x91d/0x9c0 [zfs]
[   95.287280]  [<ffffffffa0273a66>] ? spl_kmem_zalloc+0xb6/0x160 [spl]
[   95.288222]  [<ffffffffa06062d0>] ? dmu_zfetch_init+0x70/0x80 [zfs]
[   95.289146]  [<ffffffff8165fadd>] ? mutex_lock+0xd/0x2a
[   95.290070]  [<ffffffffa0607c76>] ? dmu_zfetch+0x1866/0x1b00 [zfs]
[   95.290980]  [<ffffffffa0279ecc>] ? __cv_init+0x3c/0x60 [spl]
[   95.291874]  [<ffffffffa0695930>] ? zrl_init+0x40/0x50 [zfs]
[   95.292767]  [<ffffffffa06081ad>] ? dnode_special_open+0x1d/0x20 [zfs]
[   95.293664]  [<ffffffffa05fa7a4>] ? dmu_objset_open_impl+0x704/0x820 [zfs]
[   95.294537]  [<ffffffff8165fadd>] ? mutex_lock+0xd/0x2a
[   95.295392]  [<ffffffffa061f030>] ? dsl_prop_unset_hasrecvd+0x50/0x50 [zfs]
[   95.296700]  [<ffffffffa061f041>] dsl_prop_get_all_new+0x11/0x2550 [zfs]
[   95.298130]  [<ffffffffa06669ad>] zfs_secpolicy_smb_acl+0xdd/0x6250 [zfs]
[   95.299538]  [<ffffffffa066cee4>] dataset_name_hidden+0x1e4/0x340 [zfs]
[   95.300910]  [<ffffffffa0075146>] ? avl_find+0x56/0xa0 [zavl]
[   95.302265]  [<ffffffffa06468b3>] ? unique_insert+0x113/0x130 [zfs]
[   95.303597]  [<ffffffffa060dc29>] ? dsl_dataset_hold_obj+0x509/0xb70 [zfs]
[   95.304914]  [<ffffffffa05fcb37>] dmu_objset_userquota_get_ids+0x537/0x8e0 [zfs]
[   95.306221]  [<ffffffffa027390f>] ? spl_kmem_alloc+0xbf/0x160 [spl]
[   95.307536]  [<ffffffffa05fde54>] dmu_objset_find_dp+0x144/0x1b0 [zfs]
[   95.308849]  [<ffffffffa066cd40>] ? dataset_name_hidden+0x40/0x340 [zfs]
[   95.310163]  [<ffffffffa066ee7f>] dump_list_strategy_one+0x5f/0xc0 [zfs]
[   95.311471]  [<ffffffffa066efd7>] dump_list_strategy_impl+0xf7/0x320 [zfs]
[   95.312760]  [<ffffffffa066f200>] ? dump_list_strategy_impl+0x320/0x320 [zfs]
[   95.314041]  [<ffffffffa066f219>] dump_list_strategy+0x19/0xa0 [zfs]
[   95.315301]  [<ffffffff81160349>] ? kfree+0xb9/0xf0
[   95.316552]  [<ffffffffa066f200>] ? dump_list_strategy_impl+0x320/0x320 [zfs]
[   95.317800]  [<ffffffffa0275b4c>] __thread_exit+0x8c/0xa0 [spl]
[   95.319042]  [<ffffffffa0275ae0>] ? __thread_exit+0x20/0xa0 [spl]
[   95.320287]  [<ffffffff8109cc04>] kthread+0xc4/0xe0
[   95.321512]  [<ffffffff8109cb40>] ? kthread_park+0x50/0x50
[   95.322728]  [<ffffffff816617af>] ret_from_fork+0x3f/0x70
[   95.323934]  [<ffffffff8109cb40>] ? kthread_park+0x50/0x50
[   95.325132] Code: 83 b8 20 3b 0f a0 01 5d 0f 95 c0 0f b6 c0 c3 31 c0 5d c3 66 2e 0f 1f 84 00 00 00 00 00 89 ff 55 48 8d 04 bf 48 89 e5 48 c1 e0 04 <8b> 80 0c 3b 0f a0 5d c3 66 2e 0f 1f 84 00 00 00 00 00 89 ff 55
[   95.327846] RIP  [<ffffffffa00ee2fe>] zfs_prop_get_type+0xe/0x20 [zcommon]
[   95.329146]  RSP <ffff88032735b6d8>
[   95.330428] CR2: 0000004fa00f3abc
[   95.331697] ---[ end trace 5b562f7698e8ef34 ]--

I got rid of /dev/sdi and tried to import, but almost same Oops message returned.
What is condition of my pool? Is it recoverable? What should I next?
Thanks

Environment:

saturn ~ # uname -a
Linux saturn.eska 4.4.0-gentoo-r1 #2 SMP Mon Feb 15 15:39:15 JST 2016 x86_64 AMD A10-7850K Radeon R7, 12 Compute Cores 4C+8G AuthenticAMD GNU/Linux
saturn ~ # zdb -l /dev/sda
--------------------------------------------
LABEL 0
--------------------------------------------
failed to unpack label 0
--------------------------------------------
LABEL 1
--------------------------------------------
failed to unpack label 1
--------------------------------------------
LABEL 2
--------------------------------------------
    version: 28
    name: 'zpool'
    state: 0
    txg: 17281008
    pool_guid: 1358522578922881949
    errata: 0
    hostname: 'saturn.eska'
    top_guid: 1201318286415886372
    guid: 8531825805962179935
    vdev_children: 1
    vdev_tree:
        type: 'mirror'
        id: 0
        guid: 1201318286415886372
        metaslab_array: 31
        metaslab_shift: 34
        ashift: 12
        asize: 2998440558592
        is_log: 0
        create_txg: 4
        children[0]:
            type: 'disk'
            id: 0
            guid: 9546361820085267046
            path: '/dev/sda2'
            phys_path: '/dev/gptid/064591ea-b531-11e2-9bf0-00012e312255'
            whole_disk: 1
            not_present: 1
            DTL: 4700
            create_txg: 4
        children[1]:
            type: 'disk'
            id: 1
            guid: 8531825805962179935
            path: '/dev/sdh1'
            whole_disk: 0
            DTL: 288
            create_txg: 4
    features_for_read:
--------------------------------------------
LABEL 3
--------------------------------------------
    version: 28
    name: 'zpool'
    state: 0
    txg: 17281008
    pool_guid: 1358522578922881949
    errata: 0
    hostname: 'saturn.eska'
    top_guid: 1201318286415886372
    guid: 8531825805962179935
    vdev_children: 1
    vdev_tree:
        type: 'mirror'
        id: 0
        guid: 1201318286415886372
        metaslab_array: 31
        metaslab_shift: 34
        ashift: 12
        asize: 2998440558592
        is_log: 0
        create_txg: 4
        children[0]:
            type: 'disk'
            id: 0
            guid: 9546361820085267046
            path: '/dev/sda2'
            phys_path: '/dev/gptid/064591ea-b531-11e2-9bf0-00012e312255'
            whole_disk: 1
            not_present: 1
            DTL: 4700
            create_txg: 4
        children[1]:
            type: 'disk'
            id: 1
            guid: 8531825805962179935
            path: '/dev/sdh1'
            whole_disk: 0
            DTL: 288
            create_txg: 4
    features_for_read:
saturn ~ # zdb -l /dev/sdi
--------------------------------------------
LABEL 0
--------------------------------------------
failed to unpack label 0
--------------------------------------------
LABEL 1
--------------------------------------------
failed to unpack label 1
--------------------------------------------
LABEL 2
--------------------------------------------
failed to unpack label 2
--------------------------------------------
LABEL 3
--------------------------------------------
failed to unpack label 3
saturn ~ # blkid
/dev/sda1: LABEL="zpool" UUID="1358522578922881949" UUID_SUB="8531825805962179935" TYPE="zfs_member" PARTUUID="1e94b3ed-663a-40a6-8d80-c64f98d12263"
/dev/sdi2: LABEL="zpool" UUID="1358522578922881949" UUID_SUB="9546361820085267046" TYPE="zfs_member" PARTUUID="064591ea-b531-11e2-9bf0-00012e312255"
/dev/sdi1: PARTUUID="062e7c99-b531-11e2-9bf0-00012e312255"
@pluser
Copy link
Author

pluser commented Feb 15, 2016

I tried zdb -l to partitions, not to whole disk.

saturn ~ # zdb -l /dev/sda1
--------------------------------------------
LABEL 0
--------------------------------------------
    version: 28
    name: 'zpool'
    state: 0
    txg: 17281008
    pool_guid: 1358522578922881949
    errata: 0
    hostname: 'saturn.eska'
    top_guid: 1201318286415886372
    guid: 8531825805962179935
    vdev_children: 1
    vdev_tree:
        type: 'mirror'
        id: 0
        guid: 1201318286415886372
        metaslab_array: 31
        metaslab_shift: 34
        ashift: 12
        asize: 2998440558592
        is_log: 0
        create_txg: 4
        children[0]:
            type: 'disk'
            id: 0
            guid: 9546361820085267046
            path: '/dev/sda2'
            phys_path: '/dev/gptid/064591ea-b531-11e2-9bf0-00012e312255'
            whole_disk: 1
            not_present: 1
            DTL: 4700
            create_txg: 4
        children[1]:
            type: 'disk'
            id: 1
            guid: 8531825805962179935
            path: '/dev/sdh1'
            whole_disk: 0
            DTL: 288
            create_txg: 4
    features_for_read:
--------------------------------------------
LABEL 1
--------------------------------------------
    version: 28
    name: 'zpool'
    state: 0
    txg: 17281008
    pool_guid: 1358522578922881949
    errata: 0
    hostname: 'saturn.eska'
    top_guid: 1201318286415886372
    guid: 8531825805962179935
    vdev_children: 1
    vdev_tree:
        type: 'mirror'
        id: 0
        guid: 1201318286415886372
        metaslab_array: 31
        metaslab_shift: 34
        ashift: 12
        asize: 2998440558592
        is_log: 0
        create_txg: 4
        children[0]:
            type: 'disk'
            id: 0
            guid: 9546361820085267046
            path: '/dev/sda2'
            phys_path: '/dev/gptid/064591ea-b531-11e2-9bf0-00012e312255'
            whole_disk: 1
            not_present: 1
            DTL: 4700
            create_txg: 4
        children[1]:
            type: 'disk'
            id: 1
            guid: 8531825805962179935
            path: '/dev/sdh1'
            whole_disk: 0
            DTL: 288
            create_txg: 4
    features_for_read:
--------------------------------------------
LABEL 2
--------------------------------------------
    version: 28
    name: 'zpool'
    state: 0
    txg: 17281008
    pool_guid: 1358522578922881949
    errata: 0
    hostname: 'saturn.eska'
    top_guid: 1201318286415886372
    guid: 8531825805962179935
    vdev_children: 1
    vdev_tree:
        type: 'mirror'
        id: 0
        guid: 1201318286415886372
        metaslab_array: 31
        metaslab_shift: 34
        ashift: 12
        asize: 2998440558592
        is_log: 0
        create_txg: 4
        children[0]:
            type: 'disk'
            id: 0
            guid: 9546361820085267046
            path: '/dev/sda2'
            phys_path: '/dev/gptid/064591ea-b531-11e2-9bf0-00012e312255'
            whole_disk: 1
            not_present: 1
            DTL: 4700
            create_txg: 4
        children[1]:
            type: 'disk'
            id: 1
            guid: 8531825805962179935
            path: '/dev/sdh1'
            whole_disk: 0
            DTL: 288
            create_txg: 4
    features_for_read:
--------------------------------------------
LABEL 3
--------------------------------------------
    version: 28
    name: 'zpool'
    state: 0
    txg: 17281008
    pool_guid: 1358522578922881949
    errata: 0
    hostname: 'saturn.eska'
    top_guid: 1201318286415886372
    guid: 8531825805962179935
    vdev_children: 1
    vdev_tree:
        type: 'mirror'
        id: 0
        guid: 1201318286415886372
        metaslab_array: 31
        metaslab_shift: 34
        ashift: 12
        asize: 2998440558592
        is_log: 0
        create_txg: 4
        children[0]:
            type: 'disk'
            id: 0
            guid: 9546361820085267046
            path: '/dev/sda2'
            phys_path: '/dev/gptid/064591ea-b531-11e2-9bf0-00012e312255'
            whole_disk: 1
            not_present: 1
            DTL: 4700
            create_txg: 4
        children[1]:
            type: 'disk'
            id: 1
            guid: 8531825805962179935
            path: '/dev/sdh1'
            whole_disk: 0
            DTL: 288
            create_txg: 4
    features_for_read:
saturn ~ # zdb -l /dev/sdi2
--------------------------------------------
LABEL 0
--------------------------------------------
    version: 28
    name: 'zpool'
    state: 0
    txg: 17281008
    pool_guid: 1358522578922881949
    errata: 0
    hostname: 'saturn'
    top_guid: 1201318286415886372
    guid: 9546361820085267046
    vdev_children: 1
    vdev_tree:
        type: 'mirror'
        id: 0
        guid: 1201318286415886372
        metaslab_array: 31
        metaslab_shift: 34
        ashift: 12
        asize: 2998440558592
        is_log: 0
        create_txg: 4
        children[0]:
            type: 'disk'
            id: 0
            guid: 9546361820085267046
            path: '/dev/sda2'
            phys_path: '/dev/gptid/064591ea-b531-11e2-9bf0-00012e312255'
            whole_disk: 1
            DTL: 4700
            create_txg: 4
        children[1]:
            type: 'disk'
            id: 1
            guid: 8531825805962179935
            path: '/dev/sdh1'
            whole_disk: 0
            not_present: 1
            DTL: 288
            create_txg: 4
    features_for_read:
--------------------------------------------
LABEL 1
--------------------------------------------
    version: 28
    name: 'zpool'
    state: 0
    txg: 17281008
    pool_guid: 1358522578922881949
    errata: 0
    hostname: 'saturn'
    top_guid: 1201318286415886372
    guid: 9546361820085267046
    vdev_children: 1
    vdev_tree:
        type: 'mirror'
        id: 0
        guid: 1201318286415886372
        metaslab_array: 31
        metaslab_shift: 34
        ashift: 12
        asize: 2998440558592
        is_log: 0
        create_txg: 4
        children[0]:
            type: 'disk'
            id: 0
            guid: 9546361820085267046
            path: '/dev/sda2'
            phys_path: '/dev/gptid/064591ea-b531-11e2-9bf0-00012e312255'
            whole_disk: 1
            DTL: 4700
            create_txg: 4
        children[1]:
            type: 'disk'
            id: 1
            guid: 8531825805962179935
            path: '/dev/sdh1'
            whole_disk: 0
            not_present: 1
            DTL: 288
            create_txg: 4
    features_for_read:
--------------------------------------------
LABEL 2
--------------------------------------------
    version: 28
    name: 'zpool'
    state: 0
    txg: 17281008
    pool_guid: 1358522578922881949
    errata: 0
    hostname: 'saturn'
    top_guid: 1201318286415886372
    guid: 9546361820085267046
    vdev_children: 1
    vdev_tree:
        type: 'mirror'
        id: 0
        guid: 1201318286415886372
        metaslab_array: 31
        metaslab_shift: 34
        ashift: 12
        asize: 2998440558592
        is_log: 0
        create_txg: 4
        children[0]:
            type: 'disk'
            id: 0
            guid: 9546361820085267046
            path: '/dev/sda2'
            phys_path: '/dev/gptid/064591ea-b531-11e2-9bf0-00012e312255'
            whole_disk: 1
            DTL: 4700
            create_txg: 4
        children[1]:
            type: 'disk'
            id: 1
            guid: 8531825805962179935
            path: '/dev/sdh1'
            whole_disk: 0
            not_present: 1
            DTL: 288
            create_txg: 4
    features_for_read:
--------------------------------------------
LABEL 3
--------------------------------------------
    version: 28
    name: 'zpool'
    state: 0
    txg: 17281008
    pool_guid: 1358522578922881949
    errata: 0
    hostname: 'saturn'
    top_guid: 1201318286415886372
    guid: 9546361820085267046
    vdev_children: 1
    vdev_tree:
        type: 'mirror'
        id: 0
        guid: 1201318286415886372
        metaslab_array: 31
        metaslab_shift: 34
        ashift: 12
        asize: 2998440558592
        is_log: 0
        create_txg: 4
        children[0]:
            type: 'disk'
            id: 0
            guid: 9546361820085267046
            path: '/dev/sda2'
            phys_path: '/dev/gptid/064591ea-b531-11e2-9bf0-00012e312255'
            whole_disk: 1
            DTL: 4700
            create_txg: 4
        children[1]:
            type: 'disk'
            id: 1
            guid: 8531825805962179935
            path: '/dev/sdh1'
            whole_disk: 0
            not_present: 1
            DTL: 288
            create_txg: 4
    features_for_read:

@pluser
Copy link
Author

pluser commented Feb 16, 2016

According to my investigation, this error is caused by gentoo original patch.
When I build zfs without these patch, my pool came to life.

@pluser pluser closed this as completed Feb 16, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant