diff options
author | Jeff Layton <jlayton@primarydata.com> | 2014-07-02 16:11:22 -0400 |
---|---|---|
committer | J. Bruce Fields <bfields@redhat.com> | 2014-07-08 17:14:32 -0400 |
commit | 5b8db00bae39e5ecd9bafb05478cca5b42564ab1 (patch) | |
tree | 4a66658c431b3e93aa0bdd4aa9227867739b46c7 /fs/nfsd/netns.h | |
parent | 0f3a24b43bf75adf67df188a85594a8f43b9ee93 (diff) | |
download | linux-5b8db00bae39e5ecd9bafb05478cca5b42564ab1.tar.bz2 |
nfsd: add a new /proc/fs/nfsd/max_connections file
Currently, the maximum number of connections that nfsd will allow
is based on the number of threads spawned. While this is fine for a
default, there really isn't a clear relationship between the two.
The number of threads corresponds to the number of concurrent requests
that we want to allow the server to process at any given time. The
connection limit corresponds to the maximum number of clients that we
want to allow the server to handle. These are two entirely different
quantities.
Break the dependency on increasing threads in order to allow for more
connections, by adding a new per-net parameter that can be set to a
non-zero value. The default is still to base it on the number of threads,
so there should be no behavior change for anyone who doesn't use it.
Cc: Trond Myklebust <trond.myklebust@primarydata.com>
Signed-off-by: Jeff Layton <jlayton@primarydata.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'fs/nfsd/netns.h')
-rw-r--r-- | fs/nfsd/netns.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index d32b3aa6600d..113e1aa9b0e8 100644 --- a/fs/nfsd/netns.h +++ b/fs/nfsd/netns.h @@ -102,6 +102,12 @@ struct nfsd_net { */ struct timeval nfssvc_boot; + /* + * Max number of connections this nfsd container will allow. Defaults + * to '0' which is means that it bases this on the number of threads. + */ + unsigned int max_connections; + struct svc_serv *nfsd_serv; }; |