HomeFreeBSD

nfscl: Improve "Consider increasing kern.ipc.maxsockbuf" message

Description

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.

(cherry picked from commit c5f4772c66d2eb31b84a84a89c8a284043f03452)

Details

Provenance
rmacklemAuthored on Jun 30 2021, 10:15 PM
Parents
R10:cfaec275f6b4: pf: add pf_find_state_all_exists
Branches
Unknown
Tags
Unknown