I have a small fleet of FreeBSD hosts and all are nearly identical.
Prior to upgrading to FreeBSD 13.2, I regularly open multiple concurrent ssh sessions to the servers and it has always worked. I authenticate ONLY with a password protected ssh key. The only changes in my sshd_config are to set ListenAddress (to constrain the bind to a few IPs) and PermitRootLogin without-password. After upgrading to 13.2, after I've connected with one session, subsequent concurrent ssh sessions hang forever. If I disconnect the first session, then the subsequent session will log in and work as expected. This behavior persists regardless of the user I log in as. I have tried connecting from different IP addresses and it makes no difference.
If, while connected with the first ssh session, I restart sshd with service sshd restart, then I can connect with another session. Just as often, the sshd process will wait interminably, apparently unwilling to exit while a ssh session is open. If I background the restart process and send it a kill -9, then sshd dutifully exits and then I can open a concurrent session.
Here's what it looks like on the client side when a concurrent connection is made:
It stays stuck there until the first ssh session is dropped. I tried running sshd with LogLevel DEBUG and DEBUG3. When the first session connects, there's a firehose of messages. Nothing at all is logged when the subsequent session connects and stalls. The behavior is the same when connecting over IPv4 and IPv6. I have upgraded 4 machines to 13.2 and 3 of 4 are behaving this way.
Anyone got any ideas?
Code:
# uname -a
FreeBSD ****.tnpi.net 13.2-RELEASE FreeBSD 13.2-RELEASE releng/13.2-n254617-525ecfdad597 GENERIC amd64
Prior to upgrading to FreeBSD 13.2, I regularly open multiple concurrent ssh sessions to the servers and it has always worked. I authenticate ONLY with a password protected ssh key. The only changes in my sshd_config are to set ListenAddress (to constrain the bind to a few IPs) and PermitRootLogin without-password. After upgrading to 13.2, after I've connected with one session, subsequent concurrent ssh sessions hang forever. If I disconnect the first session, then the subsequent session will log in and work as expected. This behavior persists regardless of the user I log in as. I have tried connecting from different IP addresses and it makes no difference.
If, while connected with the first ssh session, I restart sshd with service sshd restart, then I can connect with another session. Just as often, the sshd process will wait interminably, apparently unwilling to exit while a ssh session is open. If I background the restart process and send it a kill -9, then sshd dutifully exits and then I can open a concurrent session.
Here's what it looks like on the client side when a concurrent connection is made:
Code:
$ ssh -vv ****.tnpi.net
OpenSSH_8.8p1, OpenSSL 1.1.1o-freebsd 3 May 2022
debug1: Reading configuration data /etc/ssh/ssh_config
debug2: resolving "****.tnpi.net" port 22
debug1: Connecting to ****.tnpi.net [2605:7900:**:**::**] port 22.
debug1: Connection established.
debug1: identity file /home/matt/.ssh/id_rsa type 0
debug1: identity file /home/matt/.ssh/id_rsa-cert type -1
debug1: identity file /home/matt/.ssh/id_dsa type -1
debug1: identity file /home/matt/.ssh/id_dsa-cert type -1
debug1: identity file /home/matt/.ssh/id_ecdsa type -1
debug1: identity file /home/matt/.ssh/id_ecdsa-cert type -1
debug1: identity file /home/matt/.ssh/id_ecdsa_sk type -1
debug1: identity file /home/matt/.ssh/id_ecdsa_sk-cert type -1
debug1: identity file /home/matt/.ssh/id_ed25519 type -1
debug1: identity file /home/matt/.ssh/id_ed25519-cert type -1
debug1: identity file /home/matt/.ssh/id_ed25519_sk type -1
debug1: identity file /home/matt/.ssh/id_ed25519_sk-cert type -1
debug1: identity file /home/matt/.ssh/id_xmss type -1
debug1: identity file /home/matt/.ssh/id_xmss-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_8.8 FreeBSD-20211221
<insert eery silence>
It stays stuck there until the first ssh session is dropped. I tried running sshd with LogLevel DEBUG and DEBUG3. When the first session connects, there's a firehose of messages. Nothing at all is logged when the subsequent session connects and stalls. The behavior is the same when connecting over IPv4 and IPv6. I have upgraded 4 machines to 13.2 and 3 of 4 are behaving this way.
Anyone got any ideas?