Fwd: UDP port exhaustion/leak in 12.3

From: Tom <tommy7110_at_gmail.com>
Date: Tue, 01 Feb 2022 13:57:42 UTC
Hi,

Since upgrading from 12.2-RELEASE to 12.3-RELEASE a couple of days ago
I'm seeing UDP port exhaustion after a few hours. Server in question
runs bind so sees quite a fair amount of UDP traffic.

I've restarted all the major users of UDP (named. ntp, snmpd, syslog)
and that doesn't release any sockets which makes me thing it's an OS
bug, especially as it only started happening after updating to 12.3

Used UDP connections increase until the limit whereupon they fail as
shown below.
sockstat shows very few connections in use.


t7110@server1:/home/t7110 % vmstat -z | grep -E '^ITEM|inpcb':
ITEM                   SIZE  LIMIT     USED     FREE      REQ FAIL SLEEP
udp_inpcb:              316,  97392,   96560,      40,   98205,   0,   0
tcp_inpcb:              316,  97392,    6488,      40,    6600,   0,   0
udplite_inpcb:          316,  97392,       0,       0,       0,   0,   0

t7110@server1:/home/t7110 % vmstat -z | grep -E '^ITEM|inpcb':
ITEM                   SIZE  LIMIT     USED     FREE      REQ FAIL SLEEP
udp_inpcb:              316,  97392,   96615,      45,   98260,   0,   0
tcp_inpcb:              316,  97392,    6512,      52,    6624,   0,   0
udplite_inpcb:          316,  97392,       0,       0,       0,   0,   0

t7110@server1:/home/t7110 % vmstat -z | grep -E '^ITEM|inpcb':
ITEM                   SIZE  LIMIT     USED     FREE      REQ FAIL SLEEP
udp_inpcb:              316,  97392,   97109,      19,   98754,   0,   0
tcp_inpcb:              316,  97392,    6618,      30,    6730,   0,   0
udplite_inpcb:          316,  97392,       0,       0,       0,   0,   0

t7110@server1:/home/t7110 % vmstat -z | grep -E '^ITEM|inpcb':
ITEM                   SIZE  LIMIT     USED     FREE      REQ FAIL SLEEP
udp_inpcb:              316,  97392,   97176,      36,   98821,   0,   0
tcp_inpcb:              316,  97392,    6640,      32,    6752,   0,   0
udplite_inpcb:          316,  97392,       0,       0,       0,   0,   0

t7110@server1:/home/t7110 % vmstat -z | grep -E '^ITEM|inpcb':
ITEM                   SIZE  LIMIT     USED     FREE      REQ FAIL SLEEP
udp_inpcb:              316,  97392,   97207,      41,   98852,   0,   0
tcp_inpcb:              316,  97392,    6642,      30,    6754,   0,   0
udplite_inpcb:          316,  97392,       0,       0,       0,   0,   0

t7110@server1:/home/t7110 % vmstat -z | grep -E '^ITEM|inpcb':
ITEM                   SIZE  LIMIT     USED     FREE      REQ FAIL SLEEP
udp_inpcb:              316,  97392,   97317,      39,   98962,   0,   0
tcp_inpcb:              316,  97392,    6700,      32,    6812,   0,   0
udplite_inpcb:          316,  97392,       0,       0,       0,   0,   0

t7110@server1:/home/t7110 % vmstat -z | grep -E '^ITEM|inpcb':
ITEM                   SIZE  LIMIT     USED     FREE      REQ FAIL SLEEP
udp_inpcb:              316,  97392,   97329,      27,   98974,   0,   0
tcp_inpcb:              316,  97392,    6700,      32,    6812,   0,   0
udplite_inpcb:          316,  97392,       0,       0,       0,   0,   0
t7110@server1:/home/t7110 % vmstat -z | grep -E '^ITEM|inpcb':

ITEM                   SIZE  LIMIT     USED     FREE      REQ FAIL SLEEP
udp_inpcb:              316,  97392,   97352,      40,   98997,   0,   0
tcp_inpcb:              316,  97392,    6700,      32,    6812,   0,   0
udplite_inpcb:          316,  97392,       0,       0,       0,   0,   0

t7110@server1:/home/t7110 % vmstat -z | grep -E '^ITEM|inpcb':
ITEM                   SIZE  LIMIT     USED     FREE      REQ FAIL SLEEP
udp_inpcb:              316,  97392,   97392,       0,   99037, 200,   0
tcp_inpcb:              316,  97392,    6713,      19,    6825,   0,   0
udplite_inpcb:          316,  97392,       0,       0,       0,   0,   0

t7110@server1:/home/t7110 % vmstat -z | grep -E '^ITEM|inpcb':
ITEM                   SIZE  LIMIT     USED     FREE      REQ FAIL SLEEP
udp_inpcb:              316,  97392,   97392,       0,   99037, 270,   0
tcp_inpcb:              316,  97392,    6713,      19,    6825,   0,   0
udplite_inpcb:          316,  97392,       0,       0,       0,   0,   0

t7110@server1:/home/t7110 % vmstat -z | grep -E '^ITEM|inpcb':
ITEM                   SIZE  LIMIT     USED     FREE      REQ FAIL SLEEP
udp_inpcb:              316,  97392,   97392,       0,   99037, 394,   0
tcp_inpcb:              316,  97392,    6717,      15,    6829,   0,   0
udplite_inpcb:          316,  97392,       0,       0,       0,   0,   0

t7110@server1:/home/t7110 % vmstat -z | grep -E '^ITEM|inpcb':
ITEM                   SIZE  LIMIT     USED     FREE      REQ FAIL SLEEP
udp_inpcb:              316,  97392,   97392,       0,   99037, 438,   0
tcp_inpcb:              316,  97392,    6718,      14,    6830,   0,   0

Has anyone seen the same/have any suggestions? Should I open a PR for this?

thanks.

T