2011-10-06 15:11:28

by Matt W. Benjamin

[permalink] [raw]
Subject: Re: [nfsv4] back channel flags, CREATE_SESSION, BIND_CONN_TO_SESSION

Hi Trond,

The rationale for making it possible to arrive at a dedicated back channel for a session is, I think, mainly that it can yield greater throughput, a benefit which grows as workload increases. Conversely, channel negotiation appears to not have many downsides.

My reasoning would be mainly that the dedicated configuration appears to minimise the throughput potentially lost to flow control or head-of-line blocking, in particular when the the underlying transport is TCP. A slightly different way to look at it is, that it enables a simpler RPC dispatcher at both endpoints. (I doubt the latter is more than a short-term consideration. Still, having an ability to work around a class of transport/interop problems transparently, which the fallback strategy could permit, might be viewed as a win.)

If one is persuaded of the potential utility of a dedicated session back channel, it still might not appear clearly better to have the client initially propose a mixed channel and assume the server will object if it cares (as opposed to making a dedicated fore channel its initial proposal). I think the fallback strategy is slightly better. It offers both client and server input into the transport setup, and it has the benefit of being closest to what 41 servers currently do and the Linux client currently does.

As you correctly state, the client could proceed without a back channel in the presence of a "disagreeing" server and still be conformant with RFC 5661 (if perhaps not in spirit), but actually, I'm not certain that the Linux client actually does proceed as specified in this case, as presently implemented (3.1.0-rc8)--I think it may incorrectly assume that a mixed channel has been agreed on.

Back channel negotiation does what it does, seemingly, at very little cost in development (a few hundred lines, mostly structure formulas). Maintenance costs are said to be proportional to code size (or so I have read, e.g., Page-Jones). I'm not making light of this point, obviously everything has a cost.

Matt

----- "Trond Myklebust" <[email protected]> wrote:

> On Wed, 2011-10-05 at 23:28 -0400, Trond Myklebust wrote:
> > On Wed, 2011-10-05 at 19:21 -0400, Matt W. Benjamin wrote:
> > > Currently, the Linux and I believe also the CITI Windows client
> always propose channels in both directions. The Linux mainline Linux
> client doesn't know how to BIND_CONN_TO_SESSION, so trivially it won't
> negotiate any back channel if a server didn't agree to both directions
> today, either. I've experimentally implemented a "fallback" model in
> a Linux client and (partly in a) Ganesha server. I'd appreciate any
> feedback on the idea.
> >
> > Yep. As I said, why should we bother adding support for servers
> that
> > don't? I can function perfectly well without pNFS support or
> delegation
> > support in such a case. Performance will suck, but why do I care?
>
> To put it in more basic terms: what you are proposing will add
> development costs to the client and and an extra code burden to
> maintain
> long term. So what is in it for me?
>
> --
> Trond Myklebust
> Linux NFS client maintainer
>
> NetApp
> [email protected]
> http://www.netapp.com

--

Matt Benjamin

The Linux Box
206 South Fifth Ave. Suite 150
Ann Arbor, MI 48104

http://linuxbox.com

tel. 734-761-4689
fax. 734-769-8938
cel. 734-216-5309


2011-10-06 20:13:07

by Matt W. Benjamin

[permalink] [raw]
Subject: Re: [nfsv4] back channel flags, CREATE_SESSION, BIND_CONN_TO_SESSION

Hi Trond,

> For whom? We have already implemented a callback model that is working
> fine for us. I have yet to see any evidence of the callback
> scalability breakdown scenario that you claim as a motivation. What I
> have (frequently) seen is scalability issues due to clients and
> servers running out of free TCP ports.

For whom? Well, I work primarily on servers. I have worked experimentally on the Linux v41 client. I am pretty sure I wasn't speaking of a "callback scalability breakdown." I was discussing a tradeoff of ports for reduced overhead of flow control, lock contention, etc. I wasn't trying to start an inflated theory discussion about these, I don't feel fully at ease doing so. Still, I don't intuit that potential for port exhaustion trumps other considerations, it is one consideration among several. I also mentioned some potential benefit for server implementations, such as the one we have been collaborating on. I'd like to maximize its potential for success.

----- "Trond Myklebust" <[email protected]> wrote:
>
> My objection is to the lack of a consensus on a single system for
> implementing features. I'm tired of being told that the spec allows
> you to do the same thing in 10 different ways, with an expectation
> that we should implement all 10 ways.
> If we can't find a single good way of implementing a feature, then my
> preference is to drop support for that feature altogether (or to
> choose one implementation and to stick with it). My expectation for a
> standard is that it should aim to _reduce_ the number of different
> implementations so that we can concentrate our development and testing
> efforts. (BTW: pNFS is definitely not beyond criticism in this
> respect.)

You think the standard should influence, so as to reduce, the number of competing implementations? Maybe you meant 'implementation choices for <x> feature.'

My expectation from NFSv4 is that there is some room for innovation and experimentation. I don't think we can avoid this if we wish to compete effectively with ad hoc storage protocols.

>
> IOW: I can see valid reasons for why we should test the case where the
> server refuses a mixed fore+back channel, but I don't see that as a
> reason to implement a second back channel model. That requires us to
> add code + tests (and perform regular regression tests) for that back
> channel mode, as well as dealing with the case where that model of
> operation too is rejected by the server.

I find I need to keep reminding my self what "assume" does. But I assumed that the 5661 language for negotiating a back channel was in the draft (standard) because it added value to someone, and perhaps was implemented in some environment. If so, perhaps such a person will chime in with an opinion.

>
> Trond

Thanks,

Matt

--

Matt Benjamin

The Linux Box
206 South Fifth Ave. Suite 150
Ann Arbor, MI 48104

http://linuxbox.com

tel. 734-761-4689
fax. 734-769-8938
cel. 734-216-5309

2011-10-06 17:29:54

by Myklebust, Trond

[permalink] [raw]
Subject: RE: [nfsv4] back channel flags, CREATE_SESSION, BIND_CONN_TO_SESSION

PiAtLS0tLU9yaWdpbmFsIE1lc3NhZ2UtLS0tLQ0KPiBGcm9tOiBNYXR0IFcuIEJlbmphbWluIFtt
YWlsdG86bWF0dEBsaW51eGJveC5jb21dDQo+IFNlbnQ6IFRodXJzZGF5LCBPY3RvYmVyIDA2LCAy
MDExIDExOjExIEFNDQo+IFRvOiBNeWtsZWJ1c3QsIFRyb25kDQo+IENjOiBuZnN2NDsgbGludXgt
bmZzOyBuZnMtZ2FuZXNoYS1kZXZlbA0KPiBTdWJqZWN0OiBSZTogW25mc3Y0XSBiYWNrIGNoYW5u
ZWwgZmxhZ3MsIENSRUFURV9TRVNTSU9OLA0KPiBCSU5EX0NPTk5fVE9fU0VTU0lPTg0KPiANCj4g
SGkgVHJvbmQsDQo+IA0KPiBUaGUgcmF0aW9uYWxlIGZvciBtYWtpbmcgaXQgcG9zc2libGUgdG8g
YXJyaXZlIGF0IGEgZGVkaWNhdGVkIGJhY2sgY2hhbm5lbCBmb3IgYQ0KPiBzZXNzaW9uIGlzLCBJ
IHRoaW5rLCBtYWlubHkgdGhhdCBpdCBjYW4geWllbGQgZ3JlYXRlciB0aHJvdWdocHV0LCBhIGJl
bmVmaXQgd2hpY2gNCj4gZ3Jvd3MgYXMgd29ya2xvYWQgaW5jcmVhc2VzLiAgQ29udmV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c2hvdWxkIGFpbSB0byBfcmVkdWNlXyB0aGUgbnVt
YmVyIG9mIGRpZmZlcmVudCBpbXBsZW1lbnRhdGlvbnMgc28gdGhhdCB3ZSBjYW4gY29uY2VudHJh
dGUgb3VyIGRldmVsb3BtZW50IGFuZCB0ZXN0aW5nIGVmZm9ydHMuIChCVFc6IHBORlMgaXMgZGVm
aW5pdGVseSBub3QgYmV5b25kIGNyaXRpY2lzbSBpbiB0aGlzIHJlc3BlY3QuKQ0KDQpJT1c6IEkg
Y2FuIHNlZSB2YWxpZCByZWFzb25zIGZvciB3aHkgd2Ugc2hvdWxkIHRlc3QgdGhlIGNhc2Ugd2hl
cmUgdGhlIHNlcnZlciByZWZ1c2VzIGEgbWl4ZWQgZm9yZStiYWNrIGNoYW5uZWwsIGJ1dCBJIGRv
bid0IHNlZSB0aGF0IGFzIGEgcmVhc29uIHRvIGltcGxlbWVudCBhIHNlY29uZCBiYWNrIGNoYW5u
ZWwgbW9kZWwuIFRoYXQgcmVxdWlyZXMgdXMgdG8gYWRkIGNvZGUgKyB0ZXN0cyAoYW5kIHBlcmZv
cm0gcmVndWxhciByZWdyZXNzaW9uIHRlc3RzKSBmb3IgdGhhdCBiYWNrIGNoYW5uZWwgbW9kZSwg
YXMgd2VsbCBhcyBkZWFsaW5nIHdpdGggdGhlIGNhc2Ugd2hlcmUgdGhhdCBtb2RlbCBvZiBvcGVy
YXRpb24gdG9vIGlzIHJlamVjdGVkIGJ5IHRoZSBzZXJ2ZXIuDQoNClRyb25kDQo=

2011-10-07 02:27:13

by Myklebust, Trond

[permalink] [raw]
Subject: Re: [nfsv4] back channel flags, CREATE_SESSION, BIND_CONN_TO_SESSION

On Thu, 2011-10-06 at 16:12 -0400, Matt W. Benjamin wrote:
> Hi Trond,
>
> > For whom? We have already implemented a callback model that is working
> > fine for us. I have yet to see any evidence of the callback
> > scalability breakdown scenario that you claim as a motivation. What I
> > have (frequently) seen is scalability issues due to clients and
> > servers running out of free TCP ports.
>
> For whom? Well, I work primarily on servers. I have worked experimentally on the Linux v41 client. I am pretty sure I wasn't speaking of a "callback scalability breakdown." I was discussing a tradeoff of ports for reduced overhead of flow control, lock contention, etc. I wasn't trying to start an inflated theory discussion about these, I don't feel fully at ease doing so. Still, I don't intuit that potential for port exhaustion trumps other considerations, it is one consideration among several. I also mentioned some potential benefit for server implementations, such as the one we have been collaborating on. I'd like to maximize its potential for success.
>
> ----- "Trond Myklebust" <[email protected]> wrote:
> >
> > My objection is to the lack of a consensus on a single system for
> > implementing features. I'm tired of being told that the spec allows
> > you to do the same thing in 10 different ways, with an expectation
> > that we should implement all 10 ways.
> > If we can't find a single good way of implementing a feature, then my
> > preference is to drop support for that feature altogether (or to
> > choose one implementation and to stick with it). My expectation for a
> > standard is that it should aim to _reduce_ the number of different
> > implementations so that we can concentrate our development and testing
> > efforts. (BTW: pNFS is definitely not beyond criticism in this
> > respect.)
>
> You think the standard should influence, so as to reduce, the number of competing implementations? Maybe you meant 'implementation choices for <x> feature.'

I meant to say exactly what I said above: that a standard should reduce
the number of _different_ ways to implement the exact same feature. Find
something that works, and then add it to the standard. Do not waste my
time by adding experimental features and then coming back 9 months after
the standard has been published and stating that 'I just discovered that
feature A is better implemented using method X rather than method Y'.
That's not a standard: it's an experiment in progress.

> My expectation from NFSv4 is that there is some room for innovation and experimentation. I don't think we can avoid this if we wish to compete effectively with ad hoc storage protocols.

I'm not trying to compete with ad-hoc storage protocols: they can always
find a niche market to peddle their ideas. Once somebody starts talking
about a standard, then the main concept is that there is room for
cooperation in order to achieve mutual benefit. I see no benefit here.

> > IOW: I can see valid reasons for why we should test the case where the
> > server refuses a mixed fore+back channel, but I don't see that as a
> > reason to implement a second back channel model. That requires us to
> > add code + tests (and perform regular regression tests) for that back
> > channel mode, as well as dealing with the case where that model of
> > operation too is rejected by the server.
>
> I find I need to keep reminding my self what "assume" does. But I assumed that the 5661 language for negotiating a back channel was in the draft (standard) because it added value to someone, and perhaps was implemented in some environment. If so, perhaps such a person will chime in with an opinion.

Then you need to communicate that value to me. I never signed an
agreement to implement all of RFC5661.

--
Trond Myklebust
Linux NFS client maintainer

NetApp
[email protected]
http://www.netapp.com