linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Benjamin Coddington" <bcodding@redhat.com>
To: "J. Bruce Fields" <bfields@fieldses.org>
Cc: "Olga Kornievskaia" <aglo@umich.edu>,
	linux-nfs <linux-nfs@vger.kernel.org>
Subject: Re: unsharing tcp connections from different NFS mounts
Date: Wed, 07 Oct 2020 07:27:26 -0400	[thread overview]
Message-ID: <57E3293C-5C49-4A80-957B-E490E6A9B32E@redhat.com> (raw)
In-Reply-To: <20201007001814.GA5138@fieldses.org>

On 6 Oct 2020, at 20:18, J. Bruce Fields wrote:

> On Tue, Oct 06, 2020 at 05:46:11PM -0400, Olga Kornievskaia wrote:
>> On Tue, Oct 6, 2020 at 3:38 PM Benjamin Coddington 
>> <bcodding@redhat.com> wrote:
>>>
>>> On 6 Oct 2020, at 11:13, J. Bruce Fields wrote:
>>>
>>>> NFSv4.1+ differs from earlier versions in that it always performs
>>>> trunking discovery that results in mounts to the same server 
>>>> sharing a
>>>> TCP connection.
>>>>
>>>> It turns out this results in performance regressions for some 
>>>> users;
>>>> apparently the workload on one mount interferes with performance of
>>>> another mount, and they were previously able to work around the
>>>> problem
>>>> by using different server IP addresses for the different mounts.
>>>>
>>>> Am I overlooking some hack that would reenable the previous 
>>>> behavior?
>>>> Or would people be averse to an "-o noshareconn" option?
>>>
>>> I suppose you could just toggle the nfs4_unique_id parameter.  This
>>> seems to
>>> work:
>>>
>>> flock /sys/module/nfs/parameters/nfs4_unique_id bash -c 
>>> "OLD_ID=\$(cat
>>> /sys/module/nfs/parameters/nfs4_unique_id); echo imalittleteapot >
>>> /sys/module/nfs/parameters/nfs4_unique_id; mount -ov4,sec=sys
>>> 10.0.1.200:/exports /mnt/fedora2; echo \$OLD_ID >
>>> /sys/module/nfs/parameters/nfs4_unique_id"
>>>
>>> I'm trying to think of a reason why this is a bad idea, and not 
>>> coming
>>> up
>>> with any.  Can we support users that have already found this 
>>> solution?
>>>
>>
>> What about reboot recovery? How will each mount recover its own state
>> (and present the same identifier it used before). Client only keeps
>> track of one?
>
> Looks like nfs4_init_{non}uniform_client_string() stores it in
> cl_owner_id, and I was thinking that meant cl_owner_id would be used
> from then on....
>
> But actually, I think it may run that again on recovery, yes, so I bet
> changing the nfs4_unique_id parameter midway like this could cause 
> bugs
> on recovery.

Ah, that's what I thought as well.  Thanks for looking closer Olga!

I don't see why we couldn't store it for the duration of the mount, and
doing so would fix reboot recovery when the uniquifier is changed after 
a
mount.

Ben


  reply	other threads:[~2020-10-07 11:27 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-06 15:13 unsharing tcp connections from different NFS mounts J. Bruce Fields
2020-10-06 15:20 ` Chuck Lever
2020-10-06 15:22   ` Bruce Fields
2020-10-06 17:07     ` Tom Talpey
2020-10-06 19:30       ` Bruce Fields
     [not found]         ` <CAGrwUG5_KeRVR8chcA8=3FSeii2+4c8FbuE=CSGAtYVYqV4kLg@mail.gmail.com>
2020-10-07 14:08           ` Tom Talpey
2020-10-06 19:36 ` Benjamin Coddington
2020-10-06 21:46   ` Olga Kornievskaia
2020-10-07  0:18     ` J. Bruce Fields
2020-10-07 11:27       ` Benjamin Coddington [this message]
2020-10-07 12:55         ` Benjamin Coddington
2020-10-07 13:45           ` Chuck Lever
2020-10-07 14:05             ` Bruce Fields
2020-10-07 14:15               ` Chuck Lever
2020-10-07 16:05                 ` Bruce Fields
2020-10-07 16:44                   ` Trond Myklebust
2020-10-07 17:15                     ` Bruce Fields
2020-10-07 17:29                       ` Trond Myklebust
2020-10-07 18:05                         ` bfields
2020-10-07 19:11                           ` Trond Myklebust
2020-10-07 20:29                             ` bfields
2020-10-07 18:04                     ` Benjamin Coddington
2020-10-07 18:19                       ` Trond Myklebust
2020-10-07 16:50                   ` Trond Myklebust
2021-01-19 22:22                     ` bfields
2021-01-19 23:09                       ` Trond Myklebust
2021-01-20 15:07                         ` bfields
2021-05-03 20:09                           ` bfields
2021-05-04  2:08                             ` NeilBrown
2021-05-04 13:27                               ` Tom Talpey
2021-05-04 14:27                               ` Trond Myklebust
2021-05-04 16:51                                 ` bfields
2021-05-04 21:32                                   ` Daire Byrne
2021-05-04 21:48                                     ` Trond Myklebust
2021-05-05 12:53                                       ` Daire Byrne
2021-01-20 15:58                       ` Chuck Lever
2020-10-07 13:56 ` Patrick Goetz
2020-10-07 16:28   ` Igor Ostrovsky
2020-10-07 16:30   ` Benjamin Coddington

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=57E3293C-5C49-4A80-957B-E490E6A9B32E@redhat.com \
    --to=bcodding@redhat.com \
    --cc=aglo@umich.edu \
    --cc=bfields@fieldses.org \
    --cc=linux-nfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).