Project

General

Profile

Actions

Bug #7291

open

Attempting to destroy ZFS filesystem and create ZFS volume with the same name caused system panic

Added by Alex Deiter over 6 years ago. Updated almost 6 years ago.

Status:
In Progress
Priority:
Normal
Assignee:
-
Category:
-
Start date:
2016-08-10
Due date:
% Done:

0%

Estimated time:
Difficulty:
Medium
Tags:
needs-triage
Gerrit CR:
External Bug:

Description

Steps:

1. Create pool
2. Create random datasets hierarchy with random properties
3. Destroy pool
4. Re-create pool
5. Create zvol with random properties
6. Try to overwrite zvol via /opt/zfs-tests/bin/file_write with random parameters

Result:

> ::panicinfo
             cpu                2
          thread ffffff050e594c20
         message assertion failed: dv->sdev_nlink == 1, file: ../../common/fs/dev/sdev_subr.c, line: 3137
             rdi fffffffffbf58b10
             rsi ffffff001f9c61c0
             rdx fffffffffb9be6e0
             rcx              c41
              r8 fffffffffbdf68aa
              r9                0
             rax ffffff001f9c61e0
             rbx ffffff053cbf0100
             rbp ffffff001f9c6220
             r10                1
             r11                1
             r12 ffffff052fc291a0
             r13 ffffff052fc291c8
             r14 ffffff0517797830
             r15 ffffff0513cdc580
          fsbase                0
          gsbase ffffff051497b580
              ds               4b
              es               4b
              fs                0
              gs              1c3
          trapno                0
             err                0
             rip fffffffffb86c330
              cs               30
          rflags              286
             rsp ffffff001f9c61b8
              ss               38
          gdt_hi                0
          gdt_lo         f00001ef
          idt_hi                0
          idt_lo         10000fff
             ldt                0
            task               70
             cr0         8005003b
             cr2         feed5288
             cr3        434137000
             cr4            406b8

panic[cpu2]/thread=ffffff050e594c20: 
assertion failed: dv->sdev_nlink == 1, file: ../../common/fs/dev/sdev_subr.c, line: 3137

ffffff001f9c6250 genunix:process_type+17dc70 ()
ffffff001f9c62a0 dev:devname_inactive_func+99 ()
ffffff001f9c62d0 dev:sdev_inactive+1b ()
ffffff001f9c6330 genunix:fop_inactive+76 ()
ffffff001f9c6360 genunix:vn_rele+82 ()
ffffff001f9c64c0 dev:devname_lookup_func+701 ()
ffffff001f9c6550 dev:devzvol_lookup+2ae ()
ffffff001f9c6600 genunix:fop_lookup+a2 ()
ffffff001f9c6870 genunix:lookuppnvp+230 ()
ffffff001f9c6910 genunix:lookuppnatcred+15e ()
ffffff001f9c6960 genunix:lookuppnat+39 ()
ffffff001f9c6b30 genunix:vn_createat+158 ()
ffffff001f9c6ce0 genunix:vn_openat+1be ()
ffffff001f9c6e50 genunix:copen+20c ()
ffffff001f9c6e80 genunix:openat64+2a ()
ffffff001f9c6eb0 genunix:open64+25 ()
ffffff001f9c6f00 unix:brand_sys_sysenter+2b7 ()

syncing file systems...

Please try attached script.

Thank you!


Files

panic.sh (2.22 KB) panic.sh Alex Deiter, 2016-08-10 09:30 PM

Related issues

Has duplicate illumos gate - Bug #8075: Attempting to destroy ZFS filesystem and create ZFS volume with the same name caused system panicClosedYuri Pankov2017-04-16

Actions
Actions #1

Updated by Alex Deiter over 6 years ago

New title: Attempting to destroy ZFS filesystem and create ZFS volume with the same name caused system panic

Simple steps for reproducing:

zfs create -p -V 1G pool/one/two
stat /dev/zvol/dsk/pool/one/two
zfs destroy -r pool/one         
zfs create -p -V 1G pool/one    
stat /dev/zvol/dsk/pool/one

==> panic <==

Please review my pull request: https://github.com/openzfs/openzfs/pull/191

Actions #2

Updated by Yuri Pankov over 6 years ago

  • Subject changed from panic while overwriting zvol to Attempting to destroy ZFS filesystem and create ZFS volume with the same name caused system panic
Actions #3

Updated by Yuri Pankov almost 6 years ago

  • Status changed from New to Closed

Sorry, forgot about this one.

Actions #4

Updated by Yuri Pankov almost 6 years ago

  • Is duplicate of Bug #8075: Attempting to destroy ZFS filesystem and create ZFS volume with the same name caused system panic added
Actions #5

Updated by Alex Deiter almost 6 years ago

Actions #6

Updated by Yuri Pankov almost 6 years ago

  • Status changed from Closed to In Progress
Actions #7

Updated by Yuri Pankov almost 6 years ago

  • Is duplicate of deleted (Bug #8075: Attempting to destroy ZFS filesystem and create ZFS volume with the same name caused system panic)
Actions #8

Updated by Yuri Pankov almost 6 years ago

  • Has duplicate Bug #8075: Attempting to destroy ZFS filesystem and create ZFS volume with the same name caused system panic added
Actions

Also available in: Atom PDF