The issue is in the /etc/ssh/sshd_config
there is an entry in there MaxSessions
. If this is set to a number 1
, this means multiplexing is disabled. if it is set to 0
, this means that login/shell/subsystem sessions are disallowed entirely. See here for a more descriptive answer on this here https://unix.stackexchange.com/questions/26170/sshd-config-maxsessions-parameter.
Once you adjust this setting to 2 or more, (more than 2 in this case), or comment the line altogether, you have it correctly adjusted for more than 2 multiplexed connections now.
The problem was for me, After these settings were adjusted, I still wasnt able to connect to more than 2, even if i disconnected entirely and tried again.
I found the solution there was that you need to open the socket directory listed in .ssh/config
, e.g. .ssh
or .ssh/cm_socket
, then remove the socket, because it retains this info. Once you delete the socket, ensuring you have restarted the sshd daemon, then your new settings will take effect.