From nobody@FreeBSD.org  Mon Oct 28 15:21:06 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 53926561
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 28 Oct 2013 15:21:06 +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 414CD26B3
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 28 Oct 2013 15:21:06 +0000 (UTC)
Received: from oldred.freebsd.org ([127.0.1.6])
	by oldred.freebsd.org (8.14.5/8.14.7) with ESMTP id r9SFL6xS076996
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 28 Oct 2013 15:21:06 GMT
	(envelope-from nobody@oldred.freebsd.org)
Received: (from nobody@localhost)
	by oldred.freebsd.org (8.14.5/8.14.5/Submit) id r9SFL6ge076995;
	Mon, 28 Oct 2013 15:21:06 GMT
	(envelope-from nobody)
Message-Id: <201310281521.r9SFL6ge076995@oldred.freebsd.org>
Date: Mon, 28 Oct 2013 15:21:06 GMT
From: "symbolics@gmx.com" <symbolics@gmx.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: Bhyve virtio-blk cannot be a raw disc device; bad GEOM interaction
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         183401
>Category:       kern
>Synopsis:       [bhyve] bhyve virtio-blk cannot be a raw disc device; bad GEOM interaction
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Mon Oct 28 15:30:00 UTC 2013
>Closed-Date:    
>Last-Modified:  Mon Nov 18 06:26:28 UTC 2013
>Originator:     symbolics@gmx.com
>Release:        11-CURRENT
>Organization:
>Environment:
>Description:
If you try to use a raw disk with virtio-blk for a Bhyve guest you will
not be able to install the OS. grehan@ suggests this is because the
host's GEOM subsystem detects the alterations occurring within the guest.
Apparently this may also be a problem for volumes exported as iSCSI LUNs.
It would appear GEOM needs a generic way to disconnect/connect parts of
the topology from the usual tasting procedure.

I have a PoC patch that is semi-functional: it enables the installation
to complete and the guest to boot, but there are still some problems that
I need to investigate further. The patch adds a connect and disconnect
verb to the disk class, accessible via the geom utility. Using disconnect
sets a DISCONNECTED flag and removes all but the DEV consumer from the
device. The connect command removes the flag. If I can tidy it up I will
attach it to this PR. I have requested some guidance on this connect/
disconnect interface to geom@ but had no feedback as yet.
>How-To-Repeat:
Use vmrun.sh and specify a /dev/adaN device or similar instead of a file.
>Fix:


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-amd64->freebsd-bugs 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Mon Nov 18 06:24:25 UTC 2013 
Responsible-Changed-Why:  
reclassify 

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