Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755363AbbBTTFt (ORCPT ); Fri, 20 Feb 2015 14:05:49 -0500 Received: from fieldses.org ([173.255.197.46]:49795 "EHLO fieldses.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754789AbbBTTFs (ORCPT ); Fri, 20 Feb 2015 14:05:48 -0500 Date: Fri, 20 Feb 2015 14:05:47 -0500 From: "J. Bruce Fields" To: "Eric W. Biederman" Cc: Ian Kent , David Howells , Kernel Mailing List , Oleg Nesterov , Trond Myklebust , Benjamin Coddington , Al Viro , Jeff Layton Subject: Re: [RFC PATCH 5/8] KEYS: exec request-key within the requesting task's init namespace Message-ID: <20150220190547.GE18103@fieldses.org> References: <12365.1423149270@warthog.procyon.org.uk> <1423187245.3299.37.camel@pluto.fritz.box> <20150218170620.GI4148@fieldses.org> <20150218173132.GJ4148@fieldses.org> <20150218205908.GB12573@fieldses.org> <1424306341.2649.12.camel@pluto.fritz.box> <20150219013116.GA13131@fieldses.org> <1424424805.2632.24.camel@pluto.fritz.box> <20150220172558.GD18103@fieldses.org> <877fvc319o.fsf@x220.int.ebiederm.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <877fvc319o.fsf@x220.int.ebiederm.org> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1726 Lines: 42 On Fri, Feb 20, 2015 at 12:07:15PM -0600, Eric W. Biederman wrote: > "J. Bruce Fields" writes: > > > On Fri, Feb 20, 2015 at 05:33:25PM +0800, Ian Kent wrote: > > >> The case of nfsd state-recovery might be similar but you'll need to help > >> me out a bit with that too. > > > > Each network namespace can have its own virtual nfs server. Servers can > > be started and stopped independently per network namespace. We decide > > which server should handle an incoming rpc by looking at the network > > namespace associated with the socket that it arrived over. > > > > A server is started by the rpc.nfsd command writing a value into a magic > > file somewhere. > > nit. Unless I am completely turned around that file is on the nfsd > filesystem, that lives in fs/nfsd/nfs.c. > > So I bevelive this really is a case of figuring out what we want the > semantics to be for mount and propogating the information down from > mount to where we call the user mode helpers. Oops, I agree. So when I said: The upcalls need to happen consistently in one context for a given virtual nfs server, and that context should probably be derived from rpc.nfsd's somehow. Instead of "rpc.nfsd's", I think I should have said "the mounter of the nfsd filesystem". Which is already how we choose a net namespace: nfsd_mount and nfsd_fill_super store the current net namespace in s_fs_info. (And then grep for "netns" to see the places where that's used.) --b. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/