NFS tips and tricks: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
== nfsd: too many open connections, consider increasing the number of threads == | == nfsd: too many open connections, consider increasing the number of threads<ref>https://ubuntu.com/server/docs/service-nfs</ref> == | ||
NFS uses threads on the server to handle incoming and outgoing I/O requests. Using threads helps NFS scale to handle large numbers of clients and large numbers of I/O requests. | NFS uses threads on the server to handle incoming and outgoing I/O requests. Using threads helps NFS scale to handle large numbers of clients and large numbers of I/O requests. | ||
Revision as of 09:58, 2 January 2024
nfsd: too many open connections, consider increasing the number of threads[1]
NFS uses threads on the server to handle incoming and outgoing I/O requests. Using threads helps NFS scale to handle large numbers of clients and large numbers of I/O requests.
dmesg display when reach some high number of clients. should increase Number of NFS daemons (nfsd) by changing the RPCNFSDCOUNT variable in /etc/default/nfs-kernel-server
on a Debian-based machine. (Ubuntu 20.04)
Find the number of NFS daemons in two ways
ps -aux | grep nfs
or
$ ps -aux | grep nfs | wc -l
To change nfsd count temperarly, use
# rpc.nfsd 16
To change nfsd count permenently increase RPCNFSDCOUNT variable in /etc/default/nfs-kernel-server (Ubuntu 20.04)
then restart nfs server.
$ cat /etc/default/nfs-kernel-server
# Number of servers to start up
RPCNFSDCOUNT=64
...
$ sudo systemctl restart nfs-server.service
$ ps -aux | grep nfs | wc -l
65
Check nfs status
$ nfsstat -r
Server rpc stats:
calls badcalls badfmt badauth badclnt
0 0 0 0 0