]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
nfscl: Improve "Consider increasing kern.ipc.maxsockbuf" message
authorRick Macklem <rmacklem@FreeBSD.org>
Wed, 30 Jun 2021 22:15:41 +0000 (15:15 -0700)
committerRick Macklem <rmacklem@FreeBSD.org>
Wed, 30 Jun 2021 22:15:41 +0000 (15:15 -0700)
commitc5f4772c66d2eb31b84a84a89c8a284043f03452
treebc47cea606f459d964b2be943e65c699f6dbe6b6
parent447636e43c08d697664512a50f00f93f41c0a79f
nfscl: Improve "Consider increasing kern.ipc.maxsockbuf" message

When the setting of kern.ipc.maxsockbuf is less than what is
desired for I/O based on vfs.maxbcachebuf and vfs.nfs.bufpackets,
a console message of "Consider increasing kern.ipc.maxsockbuf".
is printed.

This patch modifies the message to provide a suggested value
for kern.ipc.maxsockbuf.
Note that the setting is only needed when the NFS rsize/wsize
is set to vfs.maxbcachebuf.

While here, make nfs_bufpackets global, so that it can be used
by a future patch that adds a sysctl to set the NFS server's
maximum I/O size.  Also, remove "sizeof(u_int32_t)" from the maximum
packet length, since NFS_MAXXDR is already an "overestimate"
of the actual length.

MFC after: 2 weeks
sys/fs/nfs/nfs_commonkrpc.c