Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp2578091imm; Thu, 16 Aug 2018 11:49:23 -0700 (PDT) X-Google-Smtp-Source: AA+uWPx0GJdVY80RRAJqUQVA1jb2v4I/pEEadU5H2EFN1yaTqWzeAN7iEGbADjSRJz5I5gkPdCiq X-Received: by 2002:a17:902:6907:: with SMTP id j7-v6mr30244130plk.323.1534445363807; Thu, 16 Aug 2018 11:49:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1534445363; cv=none; d=google.com; s=arc-20160816; b=y8LpI9fOa7Fg4mhuy9YttYrLH1gc1zvMMQ8y/OqPrTQR6peNd0xdRXoveYJ+VkFbZJ 6XSnh/OSMBlRA3s3lM+2NvQhOQ+HPg5CfTeWque3hDK0G/svbSYJzRHoJxCaRUCKZYEV +8sE13sh50KGCAvnZFZmYawnn3a6cF57Ik2jLrVECMaeZv3WTtGC3l5syBJWFBt+MXut VBaig1XAgnK4d9RbaX/Iqo2g/0R26vgESbbfuiQiptvJ2+Ebe5Me3XnzIJNLbFJN3Cs6 YlyFEWrOoJkMzZY6d8YOn8NF497wtWw4+CHI9tzrwqTzI7FlCxfP3GA2So9AkTr+0UBz q31Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:subject:mime-version:user-agent :message-id:in-reply-to:date:references:cc:to:from :arc-authentication-results; bh=7Eled9/s37mwV25Dkv1zRuwDDHVv20KrwvvTS0Nz/9s=; b=acSn9oQ7AnFPs3P3/kDzx8gG/Wzq0eZtZLoi6k+NQe3YfJqj8WFilrjZp1EqpeBkBG 4avfoErxlOUOdhzvX2RzGZEakGIKDLhOAxFDpff83iAxYqff28qa3ZB/A7aiet9n/Qux vsEblsy9Dgy7MT68l7GRzZXx3NcdbNck0Qogcyrn7jNZ6w6uMGW94y9bYJG5j80HbWrL H2FsY5GdahkSetPVUcdFbXObKUQn2RXRvI7XaEyBZ1uttbdtjSbwSpoUIYWL7Ald2C4u VREdmR1VqjyR0mmmAfijdZxxo5CqdSDIt6zpDwjsCH9m+6uDSwHcaDVJ+ID+aNoIhwNi WbUQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b16-v6si14391pgg.342.2018.08.16.11.49.08; Thu, 16 Aug 2018 11:49:23 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728507AbeHPUVX (ORCPT + 99 others); Thu, 16 Aug 2018 16:21:23 -0400 Received: from out03.mta.xmission.com ([166.70.13.233]:47274 "EHLO out03.mta.xmission.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725969AbeHPUVW (ORCPT ); Thu, 16 Aug 2018 16:21:22 -0400 Received: from in02.mta.xmission.com ([166.70.13.52]) by out03.mta.xmission.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.87) (envelope-from ) id 1fqLxj-0004nO-0o; Thu, 16 Aug 2018 11:21:31 -0600 Received: from [97.119.167.31] (helo=x220.xmission.com) by in02.mta.xmission.com with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.87) (envelope-from ) id 1fqLxi-0004Ug-Aw; Thu, 16 Aug 2018 11:21:30 -0600 From: ebiederm@xmission.com (Eric W. Biederman) To: Steve French Cc: David Howells , trond.myklebust@hammerspace.com, Anna Schumaker , Steve French , Steve Dickson , Al Viro , Linus Torvalds , ebiederm@redhat.com, linux-api@vger.kernel.org, linux-security-module@vger.kernel.org, linux-fsdevel , LKML , linux-nfs@vger.kernel.org, CIFS , linux-afs@lists.infradead.org, ceph-devel@vger.kernel.org, v9fs-developer@lists.sourceforge.net References: <153313703562.13253.5766498657900728120.stgit@warthog.procyon.org.uk> <17763.1534350685@warthog.procyon.org.uk> <87pnyiew8x.fsf@xmission.com> Date: Thu, 16 Aug 2018 12:21:23 -0500 In-Reply-To: (Steve French's message of "Thu, 16 Aug 2018 11:24:56 -0500") Message-ID: <87in4acjn0.fsf@xmission.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-XM-SPF: eid=1fqLxi-0004Ug-Aw;;;mid=<87in4acjn0.fsf@xmission.com>;;;hst=in02.mta.xmission.com;;;ip=97.119.167.31;;;frm=ebiederm@xmission.com;;;spf=neutral X-XM-AID: U2FsdGVkX18gCLRR5hyEu8VeoAcvITnRRHb6CUf2MKU= X-SA-Exim-Connect-IP: 97.119.167.31 X-SA-Exim-Mail-From: ebiederm@xmission.com X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on sa06.xmission.com X-Spam-Level: X-Spam-Status: No, score=0.5 required=8.0 tests=ALL_TRUSTED,BAYES_50, DCC_CHECK_NEGATIVE,T_TM2_M_HEADER_IN_MSG,XMSubLong autolearn=disabled version=3.4.1 X-Spam-Report: * -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP * 0.7 XMSubLong Long Subject * 0.0 T_TM2_M_HEADER_IN_MSG BODY: No description available. * 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% * [score: 0.5000] * -0.0 DCC_CHECK_NEGATIVE Not listed in DCC * [sa06 1397; Body=1 Fuz1=1 Fuz2=1] X-Spam-DCC: XMission; sa06 1397; Body=1 Fuz1=1 Fuz2=1 X-Spam-Combo: ;Steve French X-Spam-Relay-Country: X-Spam-Timing: total 319 ms - load_scoreonly_sql: 0.04 (0.0%), signal_user_changed: 3.8 (1.2%), b_tie_ro: 2.4 (0.8%), parse: 1.39 (0.4%), extract_message_metadata: 20 (6.3%), get_uri_detail_list: 2.6 (0.8%), tests_pri_-1000: 9 (2.9%), tests_pri_-950: 1.51 (0.5%), tests_pri_-900: 1.45 (0.5%), tests_pri_-400: 28 (8.7%), check_bayes: 26 (8.3%), b_tokenize: 9 (2.9%), b_tok_get_all: 8 (2.4%), b_comp_prob: 3.3 (1.0%), b_tok_touch_all: 2.5 (0.8%), b_finish: 0.68 (0.2%), tests_pri_0: 244 (76.4%), check_dkim_signature: 0.70 (0.2%), check_dkim_adsp: 4.4 (1.4%), tests_pri_500: 5 (1.7%), rewrite_mail: 0.00 (0.0%) Subject: Re: Should we split the network filesystem setup into two phases? X-Spam-Flag: No X-SA-Exim-Version: 4.2.1 (built Thu, 05 May 2016 13:38:54 -0600) X-SA-Exim-Scanned: Yes (on in02.mta.xmission.com) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Steve French writes: > On Thu, Aug 16, 2018 at 2:56 AM Eric W. Biederman wrote: >> >> David Howells writes: >> >> > Having just re-ported NFS on top of the new mount API stuff, I find that I >> > don't really like the idea of superblocks being separated by communication >> > parameters - especially when it might seem reasonable to be able to adjust >> > those parameters. >> > >> > Does it make sense to abstract out the remote peer and allow (a) that to be >> > configured separately from any superblocks using it and (b) that to be used to >> > create superblocks? > >> At least for devpts we always create a new filesystem instance every >> time mount(2) is called. NFS seems to have the option to create a new >> filesystem instance every time mount(2) is called as well, (even if the >> filesystem parameters are the same). And depending on the case I can >> see the attraction for other filesystems as well. >> >> So I don't think we can completely abandon the option for filesystems >> to always create a new filesystem instance when mount(8) is called. > > In cifs we attempt to match new mounts to existing tree connections > (instances of connections to a \\server\share) from other mount(s) > based first on whether security settings match (e.g. are both > Kerberos) and then on whether encryption is on/off and whether this is > a snapshot mount (smb3 previous versions feature). If neither is > mounted with a snaphsot and the encryption settings match then > we will use the same tree id to talk with the server as the other > mounts use. Interesting idea to allow mount to force a new > tree id. > > What was the NFS mount option you were talking about? > Looking at the nfs man page the only one that looked similar > was "nosharecache" I was remembering this from reading the nfs mount code: static int nfs_compare_super(struct super_block *sb, void *data) { ... if (!nfs_compare_super_address(old, server)) return 0; /* Note: NFS_MOUNT_UNSHARED == NFS4_MOUNT_UNSHARED */ if (old->flags & NFS_MOUNT_UNSHARED) return 0; ... } If a filesystem has NFS_MOUNT_UNSHARED set it does not serve as a candidate for new mount requests. Skimming the code it looks like nosharecache is what sets NFS_MOUNT_UNSHARED. Another interesting and common case is tmpfs which always creates a new filesystem instance whenever it is mounted. Eric