From nobody@FreeBSD.org  Mon Aug 12 05:11:17 2013
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1])
	(using TLSv1 with cipher ADH-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by hub.freebsd.org (Postfix) with ESMTP id DD916D89
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 12 Aug 2013 05:11:17 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from oldred.freebsd.org (oldred.freebsd.org [8.8.178.121])
	(using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by mx1.freebsd.org (Postfix) with ESMTPS id CBB5E2A28
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 12 Aug 2013 05:11:17 +0000 (UTC)
Received: from oldred.freebsd.org ([127.0.1.6])
	by oldred.freebsd.org (8.14.5/8.14.7) with ESMTP id r7C5BHhX025554
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 12 Aug 2013 05:11:17 GMT
	(envelope-from nobody@oldred.freebsd.org)
Received: (from nobody@localhost)
	by oldred.freebsd.org (8.14.5/8.14.5/Submit) id r7C5BHKf025536;
	Mon, 12 Aug 2013 05:11:17 GMT
	(envelope-from nobody)
Message-Id: <201308120511.r7C5BHKf025536@oldred.freebsd.org>
Date: Mon, 12 Aug 2013 05:11:17 GMT
From: Christopher Harrison <harrison@glsan.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: zfs block devices not appearing after zfs recv
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         181235
>Category:       kern
>Synopsis:       [zfs] zfs block devices not appearing after zfs recv
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    smh
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Aug 12 05:20:00 UTC 2013
>Closed-Date:    
>Last-Modified:  Tue Aug 13 03:50:00 UTC 2013
>Originator:     Christopher Harrison
>Release:        9.1-RELEASE
>Organization:
>Environment:
# uname -a
FreeBSD s1 9.1-RELEASE FreeBSD 9.1-RELEASE #0 r243825: Tue Dec  4 09:23:10 UTC 2012     root@farrell.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  amd64

>Description:
When using zfs send of snapshots I am recieving the stream into a zfs recv pipe 
"zfs send -R ... | ssh test1 "zfs recv -vF -d ..."   

The problem occurs if I want to use the newly received zfs block device after the receive completes.   The data is shown as completed.   The zfs send stream show complete.   zfs get all lists the proper sizes and info for the newly created data set.   However the /dev/zvol/... device is not there.   

The only way I have been able to force the zfs block device to be exposed to the /dev file tree is through a zpool export, zpool import.   Otherwise the zfs block dev is not accessible nor available though the normal block devfs.



>How-To-Repeat:
create a zpool
create a zfs block dev (zfs create -V 10G -b 4k z/volumes/test123 )
snapshot the zfs block dev (zfs snapshot z/volumes/test123@201308010)
zfs send the snapshot (zfs send -R z/volumes/test123@201308010 | ssh mytest "zfs recv -vF -d ztest"
Let the zfs send/recv complete
try to access the newly received zfs block dev (ls -la /dev/zvol/ztest/volumes/test123, no found).
>Fix:


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->freebsd-fs 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Tue Aug 13 03:13:02 UTC 2013 
Responsible-Changed-Why:  
Over to maintainer(s). 

http://www.freebsd.org/cgi/query-pr.cgi?pr=181235 
Responsible-Changed-From-To: freebsd-fs->smh 
Responsible-Changed-By: smh 
Responsible-Changed-When: Tue Aug 13 03:48:20 UTC 2013 
Responsible-Changed-Why:  
I'll take it. 

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

From: "Steven Hartland" <killing@multiplay.co.uk>
To: <bug-followup@freebsd.org>,
	"Christopher Harrison" <harrison@glsan.com>
Cc:  
Subject: Re: kern/181235: [zfs] zfs block devices not appearing after zfs recv
Date: Tue, 13 Aug 2013 04:48:06 +0100

 Please try the patch attached to:
 http://www.freebsd.org/cgi/query-pr.cgi?pr=178999
 
 ================================================
 This e.mail is private and confidential between Multiplay (UK) Ltd. and the person or entity to whom it is addressed. In the event of misdirection, the recipient is prohibited from using, copying, printing or otherwise disseminating it or any information contained in it. 
 
 In the event of misdirection, illegible or incomplete transmission please telephone +44 845 868 1337
 or return the E.mail to postmaster@multiplay.co.uk.
 
>Unformatted:
