From nobody@FreeBSD.org  Thu Dec 17 16:43:06 2009
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id BBAB81065670
	for <freebsd-gnats-submit@FreeBSD.org>; Thu, 17 Dec 2009 16:43:06 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21])
	by mx1.freebsd.org (Postfix) with ESMTP id AA5108FC15
	for <freebsd-gnats-submit@FreeBSD.org>; Thu, 17 Dec 2009 16:43:06 +0000 (UTC)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.14.3/8.14.3) with ESMTP id nBHGh6NF047916
	for <freebsd-gnats-submit@FreeBSD.org>; Thu, 17 Dec 2009 16:43:06 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.3/8.14.3/Submit) id nBHGh6JM047915;
	Thu, 17 Dec 2009 16:43:06 GMT
	(envelope-from nobody)
Message-Id: <200912171643.nBHGh6JM047915@www.freebsd.org>
Date: Thu, 17 Dec 2009 16:43:06 GMT
From: Ben Schumacher <me@benschumacher.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: kernel panic when 'zfs rename' is used on mounted snapshot
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         141718
>Category:       kern
>Synopsis:       [zfs] [panic] kernel panic when 'zfs rename' is used on mounted snapshot
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    pjd
>State:          feedback
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Dec 17 16:50:02 UTC 2009
>Closed-Date:    
>Last-Modified:  Thu Apr 22 19:09:59 UTC 2010
>Originator:     Ben Schumacher
>Release:        FreeBSD 8.0-RELEASE-p1 i386
>Organization:
>Environment:
System: FreeBSD filer.sats.internal 8.0-RELEASE-p1 FreeBSD 8.0-RELEASE-p1 #0: Tue Dec 15 01:05:20 MST 2009 ben@filer.sats.internal:/usr/obj/data/FreeBSD/RELENG_8_0/src/sys/FILER i386
>Description:
While using RSE's 'snapshot' tool with a ZFS-based system I observed that
calling 'snapshot make' on a drive that has a mounted snapshot causes a panic.
It would appear that the 'zfs rename' call inside the utility being executed
to rename a snapshot that is mounted causes the panic.

Unfortunately I don't have a dump because the system appeared to hang during
the panic (no automatic reboot), so I had to manually power cycle it to get
it back up.
>How-To-Repeat:
1. Create zfs snapshot of drive.
2. Mount zfs snapshot somewhere on system.
3. Use 'zfs rename' to chnage the name of the mounted snapshot.
4. Observe kernel panic.
>Fix:
Workaround: Don't 'zfs rename' a mounted snapshot. It'd be nice, however, if
the OS blocked the operations and didn't panic.


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->freebsd-fs 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Thu Dec 17 16:57:01 UTC 2009 
Responsible-Changed-Why:  
Over to maintainer(s). 

http://www.freebsd.org/cgi/query-pr.cgi?pr=141718 
Responsible-Changed-From-To: freebsd-fs->pjd 
Responsible-Changed-By: pjd 
Responsible-Changed-When: ptk 19 mar 2010 23:15:20 UTC 
Responsible-Changed-Why:  
I'll take this one. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=141718 
State-Changed-From-To: open->feedback 
State-Changed-By: pjd 
State-Changed-When: czw 22 kwi 2010 19:09:10 UTC 
State-Changed-Why:  
Unfortunately I'm unable to reproduce the problem you reported. 
'zfs rename' on mounted snapshot works just fine. 
Is there anything else I should try? 

http://www.freebsd.org/cgi/query-pr.cgi?pr=141718 
>Unformatted:
