On Mon, 2013-07-22 at 19:02 +0000, Adamson, Andy wrote: > On Jul 22, 2013, at 2:36 PM, "Myklebust, Trond" <Trond.Myklebust@xxxxxxxxxx> > wrote: > > > On Fri, 2013-07-19 at 17:09 -0400, andros@xxxxxxxxxx wrote: > >> From: Andy Adamson <andros@xxxxxxxxxx> > >> > >> max_session_slots is a ushort. Bump NFS4_DEF_SLOT_TABLE_SIZE to the max ushort > >> value: e.g. ask for 256 slots and let the server negotiate down if needed. > >> > >> Signed-off-by: Andy Adamson <andros@xxxxxxxxxx> > >> --- > >> fs/nfs/nfs4session.h | 2 +- > >> 1 file changed, 1 insertion(+), 1 deletion(-) > >> > >> diff --git a/fs/nfs/nfs4session.h b/fs/nfs/nfs4session.h > >> index 3a153d8..8b7899f 100644 > >> --- a/fs/nfs/nfs4session.h > >> +++ b/fs/nfs/nfs4session.h > >> @@ -8,7 +8,7 @@ > >> #define __LINUX_FS_NFS_NFS4SESSION_H > >> > >> /* maximum number of slots to use */ > >> -#define NFS4_DEF_SLOT_TABLE_SIZE (16U) > >> +#define NFS4_DEF_SLOT_TABLE_SIZE (256U) > > > > Could we please make this smaller? I agree that 16 is too small (as long > > as servers don't do dynamic slot allocation), but 256 is very high for a > > default. > > > > How about 64? > > IIIRC the (non-dynamic) session implemenations that I've seen treat the ca_maxrequests coming from the client as the maximum number of session slots that the client can handle - IOW I don't see servers returning a higher ca_maxrequests than was sent by the client. This is why I chose a larger number for the default. It is, after all, a server resource and shouldn't the client grab as many session slots as it can? The problem is that once you implement dynamic slot tables, the negotiated session slot table size becomes the _minimum_ number of slots. That's why a client that supports dynamic slot tables wants to keep the ca_maxrequests _small_ in the hope that the server can then dynamically adjust the total number of slots upwards in order to meet the actual load. -- Trond Myklebust Linux NFS client maintainer NetApp Trond.Myklebust@xxxxxxxxxx www.netapp.com ��.n��������+%������w��{.n�����{��w���jg��������ݢj����G�������j:+v���w�m������w�������h�����٥