From mboxrd@z Thu Jan 1 00:00:00 1970 From: Sasha Levin Subject: Re: [PATCH 2/2] kvm tools: Add virtio-9p Date: Wed, 18 May 2011 13:35:31 +0300 Message-ID: <1305714931.12150.76.camel@sasha> References: <1305657337-2584-1-git-send-email-levinsasha928@gmail.com> <1305657337-2584-2-git-send-email-levinsasha928@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: mingo@elte.hu, asias.hejun@gmail.com, prasadjoshi124@gmail.com, gorcunov@gmail.com, kvm@vger.kernel.org, Eric Van Hensbergen , jvrao To: Pekka Enberg Return-path: Received: from mail-bw0-f46.google.com ([209.85.214.46]:65426 "EHLO mail-bw0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755620Ab1ERKfg (ORCPT ); Wed, 18 May 2011 06:35:36 -0400 Received: by bwz15 with SMTP id 15so1286322bwz.19 for ; Wed, 18 May 2011 03:35:35 -0700 (PDT) In-Reply-To: Sender: kvm-owner@vger.kernel.org List-ID: On Wed, 2011-05-18 at 09:38 +0300, Pekka Enberg wrote: > On Tue, May 17, 2011 at 9:35 PM, Sasha Levin wrote: > > Overview: > > 9p allows for simple RPC based resource sharing over > > different transports (in our case, virtio). > > > > This is the implementation of (most of) the original > > 9p2000 protocol, without the .u or the .l extensions. > > > > How to use: > > 1. Make sure kernel is compiled with: > > CONFIG_NET_9P=y > > CONFIG_NET_9P_VIRTIO=y > > CONFIG_NET_9P_DEBUG=y (At least until code is stable) > > CONFIG_9P_FS=y > > > > 2. Start KVM with '--virtio-9p '. What happens now is that > > a virtio transport with the name 'kvm_9p' is created. The server side > > of the transport maps dirname to the root of the file system. > > > > 3. Within the guest, mount the fs: > > mount -t 9p -otrans=virtio kvm_9p -oversion=9p2000 > > This will mount the 9p server to local_dir. > > This is really cool, Sasha! I'd like to see host "/" mounted as > "/host" automatically in the guest. If that's too radical, we could go > for mounting $HOME. I guess it's pretty trivial to do on the > hypervisor side but can we do that for unmodified guests (not > necessarily unmodified guest kernels, though)? > > Pekka I'm not sure how to do the guest part automatically, it's just a simple mount command - but I don't see how we can do it in a simple manner. -- Sasha.