From nobody@FreeBSD.org  Wed Mar 31 08:54:06 2010
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 99AE3106564A
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 31 Mar 2010 08:54: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 88A598FC16
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 31 Mar 2010 08:54: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 o2V8s5wT013059
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 31 Mar 2010 08:54:05 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.3/8.14.3/Submit) id o2V8s5Uj013052;
	Wed, 31 Mar 2010 08:54:05 GMT
	(envelope-from nobody)
Message-Id: <201003310854.o2V8s5Uj013052@www.freebsd.org>
Date: Wed, 31 Mar 2010 08:54:05 GMT
From: Dmitry Afanasiev <KOT@MATPOCKuH.Ru>
To: freebsd-gnats-submit@FreeBSD.org
Subject: zvol with org.freebsd:swap=on crashes zfs list
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         145234
>Category:       kern
>Synopsis:       [zfs] zvol with org.freebsd:swap=on crashes zfs list
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-fs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Mar 31 09:00:14 UTC 2010
>Closed-Date:    Wed Apr 07 22:03:32 UTC 2010
>Last-Modified:  Wed Apr 07 22:03:32 UTC 2010
>Originator:     Dmitry Afanasiev
>Release:        FreeBSD 9.0-CURRENT amd64
>Organization:
>Environment:
FreeBSD green 9.0-CURRENT FreeBSD 9.0-CURRENT #66: Tue Mar 30 19:33:40 MSD 2010     root@green:/usr/obj/usr/src/sys/green  amd64

>Description:
Only on fresh current:
# zfs create -V 128m rpool/test
# zfs list rpool/test
NAME           USED  AVAIL  REFER  MOUNTPOINT
rpool/test     128M  55.9G    16K  -
# zfs set org.freebsd:swap=on rpool/test
# zfs list rpool/test
Segmentation fault (core dumped)
# zfs list
Segmentation fault (core dumped)
# zfs inherit org.freebsd:swap rpool/test
# zfs list rpool/test
NAME           USED  AVAIL  REFER  MOUNTPOINT
rpool/test   128M  55.9G    16K  -

backtrace looks like this:
(gdb) bt
#0  0x0000000800662730 in zfs_prune_proplist () from /lib/libzfs.so.2
#1  0x000000000040abf2 in ?? ()
#2  0x0000000800664694 in zfs_iter_filesystems () from /lib/libzfs.so.2
#3  0x000000000040abe1 in ?? ()
#4  0x000000080065718c in zfs_iter_root () from /lib/libzfs.so.2
#5  0x000000000040ae7f in ?? ()
#6  0x0000000000406a70 in ?? ()
#7  0x0000000000408639 in ?? ()
#8  0x0000000000403bfe in ?? ()
#9  0x000000080053b000 in ?? ()
#10 0x0000000000000000 in ?? ()
#11 0x0000000000000000 in ?? ()
#12 0x0000000000000002 in ?? ()
#13 0x00007fffffffeeb0 in ?? ()
#14 0x00007fffffffeeb4 in ?? ()
#15 0x0000000000000000 in ?? ()
#16 0x00007fffffffeeb9 in ?? ()
..

I have this problem on fresh amd64 and sparc64 systems.
zfs get all rpool/test works without problems.

Also this fails automatic swap setup in /etc/rc.d/zfs.
>How-To-Repeat:

>Fix:


>Release-Note:
>Audit-Trail:

From: Dmitry Afanasiev <KOT@MATPOCKuH.Ru>
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: bin/145234: zvol with org.freebsd:swap=on crashes zfs list
Date: Wed, 31 Mar 2010 14:16:53 +0400

 I'm sorry, /etc/rc.d/zvol is a correct script name, that fails to 
 configure swap area.
Responsible-Changed-From-To: freebsd-bugs->freebsd-fs 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Tue Apr 6 05:21:32 UTC 2010 
Responsible-Changed-Why:  
Even though the bug shows up in a binary, I'm going out on a limb 
and assigning it to the fs@ mailing list, where most of the other 
zfs bugs have been assigned. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=145234 

From: Andriy Gapon <avg@icyb.net.ua>
To: bug-followup@FreeBSD.org, KOT@MATPOCKuH.Ru
Cc:  
Subject: Re: kern/145234: [zfs] zvol with org.freebsd:swap=on crashes zfs
 list
Date: Tue, 06 Apr 2010 09:54:06 +0300

 This should be resolved in head now.
 See r206199 (http://svn.freebsd.org/changeset/base/206199)
 And kern/145377.
 
 -- 
 Andriy Gapon

From: Dmitry Afanasiev <KOT@MATPOCKuH.Ru>
To: Andriy Gapon <avg@icyb.net.ua>
Cc: bug-followup@FreeBSD.org
Subject: Re: kern/145234: [zfs] zvol with org.freebsd:swap=on crashes zfs
 list
Date: Wed, 07 Apr 2010 17:16:32 +0400

 On 06.04.2010 10:54, Andriy Gapon wrote:
 > This should be resolved in head now.
 Yes, after update "zfs list" is working properly.
 Please close PR.
State-Changed-From-To: open->closed 
State-Changed-By: avg 
State-Changed-When: Wed Apr 7 21:59:08 UTC 2010 
State-Changed-Why:  
The issue is resolved in head (the only branch where 
the problem existed). 

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