HomeFreeBSD

MFC: listen(2): improve administrator control over logging

Description

MFC: listen(2): improve administrator control over logging

As documented in listen.2 manual page, the kernel emits a LOG_DEBUG
syslog message if a socket listen queue overflows. For some appliances,
it may be desirable to change the priority to some higher value
like LOG_INFO while keeping other debugging suppressed.

OTOH there are cases when such overflows are normal and expected.
Then it may be desirable to suppress overflow logging altogether,
so that dmesg buffer is not flooded over long run.

In addition to existing sysctl kern.ipc.sooverinterval,
introduce new sysctl kern.ipc.sooverprio that defaults to 7 (LOG_DEBUG)
to preserve current behavior. It may be changed to any value
in a range of 0..7 for corresponding priority or to -1 to suppress logging.
Document it in the listen.2 manual page.

(cherry picked from commit 4824d788725987bccff53dec8c103cbac455b3ed)

Details

Provenance
eugen_grosbein.netAuthored on Apr 30 2023, 8:14 PM
Parents
rG097e721ff4f2: geli: fix typo
Branches
Unknown
Tags
Unknown