From owner-freebsd-virtualization@FreeBSD.ORG Wed Apr 9 17:36:06 2014 Return-Path: Delivered-To: freebsd-virtualization@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 ESMTPS id 2727FE37; Wed, 9 Apr 2014 17:36:06 +0000 (UTC) Received: from alto.onthenet.com.au (alto.OntheNet.com.au [203.13.68.12]) by mx1.freebsd.org (Postfix) with ESMTP id DC1B016AE; Wed, 9 Apr 2014 17:36:05 +0000 (UTC) Received: from dommail.onthenet.com.au (dommail.OntheNet.com.au [203.13.70.57]) by alto.onthenet.com.au (Postfix) with ESMTPS id 2873A12496; Thu, 10 Apr 2014 03:36:04 +1000 (EST) Received: from Peter-Grehans-MacBook-Pro-2.local ([198.95.226.236]) by dommail.onthenet.com.au (MOS 4.2.4-GA) with ESMTP id BTF94220 (AUTH peterg@ptree32.com.au); Thu, 10 Apr 2014 03:36:03 +1000 Message-ID: <534584FE.60807@freebsd.org> Date: Wed, 09 Apr 2014 10:35:58 -0700 From: Peter Grehan User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 MIME-Version: 1.0 To: Roman Bogorodskiy Subject: Re: bhyve: allow specifiying tty by fd References: <20140305130030.GA40560@dev.san.ru> <5318BF7F.4060306@freebsd.org> <20140409172657.GB1313@kloomba> In-Reply-To: <20140409172657.GB1313@kloomba> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-virtualization@freebsd.org X-BeenThere: freebsd-virtualization@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: "Discussion of various virtualization techniques FreeBSD supports." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 09 Apr 2014 17:36:06 -0000 Hi Roman, >>> bhyve -s 31,lpc -l com1,fd=19 vm0 >> >> Yes, useful idea, and will become more relevant in the capsicum world >> of passing fd's to a sandboxed bhyve. >> >> Thanks: I'll get this submitted. > > Hi Peter! > > Any news on that? I started to do it, and then hesitated bit for two reasons. First, it's useful for all backends, but there still needs to be a type - file descriptors can't be treated as something opaque: there still needs to be knowledge of whether it's a socket, char device, file etc, so the option may need additional information to describe that. Also, given that Capsicum wants to pass fd's as parameters, I was wondering if there is a general syntax style for doing this. "fd=%d" seems Ok, though it would be useful if there was something in libutil to parse an option like this if it is the preferred way forward for FreeBSD executables. What do folk think ? Any useful precedents ? later, Peter.