SSH problem on macOS 15.6.1

Soldato
Joined
1 Nov 2007
Posts
7,253
Location
England
I normally use SSH quite often and have never had a problem until recently. Now when I try and SSH into a server it just hangs and will eventually time out. This occurs when accessing devices on the local network (RPi running PiHole) and on servers run by Linode and probably others as well. Does anyone have any ideas of what is going on? Even when I specify -vvv there isn't much information other than it hangs. Not sure what else to try.
 
I recently updated to 15.6.1 and am not experiencing this issue.

Which terminal emulator are you using? Tried another?

Disabled private relay?

Other ports like 443 and services locally available otherwise?
 
I recently updated to 15.6.1 and am not experiencing this issue.

Which terminal emulator are you using? Tried another?

Disabled private relay?

Other ports like 443 and services locally available otherwise?
I use iTerm2 as the Terminal app. The same problem happens on the Apple Terminal app. I don't use Private Relay. The server is up and running and accepting WebDAV and HTTPS connections.

Thanks for the reply.
 
You could try nmap to see what ports are available.

At this point I’d be checking the firewall hasn’t changed as well. If you have one on the clients or router.
 
You could try nmap to see what ports are available.

At this point I’d be checking the firewall hasn’t changed as well. If you have one on the clients or router.
Thank you again. I'll have a play around tomorrow morning when I have a bit more free time and check those things out.
 
I did some more searching and it actually looks like a really common and persistent issue with MacOS. Some other options:

- Try different ssh cipher
- Try Ethernet or with/without any docks
- Disable MacOS firewall and try again

On this basis, I would also try another machine or client (even a phone can ssh with certain apps - I use terminus on iOS). This may isolate the issue to the Mac at least.
 
Well I did a little testing and SSH works perfectly in a virtual machine running RHEL 10 so it is not a problem with the server. The same problem happens on my MBA though so something is being weird in macOS. I think I'll wait til macOS 26 comes out tomorrow to see if that fixes it before I spend a load of time trying to fix the issue.

Thank you for your help. I appreciate it.
 
Sounds like a plan. Fingers crossed.

I unfortunately can’t test 26 until OCLP is ready as my MacBook is a mid-2014.
 
Hmm. There is an OpenSSH package in homebrew but not sure how that works. I assume it just places itself higher up in the PATH and therefore it will use the homebrew package by default. I might have to try that out.
 
Worth a go.

Could also try adding the SSH binary manually to be allowed through the MacOS firewall.

Do you get a better output using ssh -v ?
 
Tried the homebrew package and that didn't work. I get no real useful information with -v it just hangs at the connection attempt stage.

I guess I'll just have to use a VM for SSH for the time being. I'll do some searching and see if I can find anymore information.
 
I use ssh on a daily bases to other macs and RHEL servers and not experienced any issues at all at work...
and ssh into other macs, CLI only version of RPi, and ubuntu at home.. again no issues...

do you have a ssh config file setup on your machine?

try using an app like termius which has it's own config setup to rule out settings on your device itself.
 
I use ssh on a daily bases to other macs and RHEL servers and not experienced any issues at all at work...
and ssh into other macs, CLI only version of RPi, and ubuntu at home.. again no issues...

do you have a ssh config file setup on your machine?

try using an app like termius which has it's own config setup to rule out settings on your device itself.
Thank you. I'll try out Termius. Strange that it only happens on my Macs but works fine in a virtual machine. The debug output isn't helpful at all unfortunately.
 
Just tried Termius. Doesn't work. This is the debug output from ssh:

Code:
debug1: OpenSSH_10.0p2, LibreSSL 3.3.6
debug3: Running on Darwin 25.0.0 Darwin Kernel Version 25.0.0: Mon Aug 25 21:17:45 PDT 2025; root:xnu-12377.1.9~3/RELEASE_ARM64_T8103 arm64
debug3: Started with: ssh [email protected] -vvv
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 21: include /etc/ssh/ssh_config.d/* matched no files
debug1: /etc/ssh/ssh_config line 54: Applying options for *
debug2: resolve_canonicalize: hostname 192.168.50.61 is address
debug3: expanded UserKnownHostsFile '~/.ssh/known_hosts' -> '/Users/simon/.ssh/known_hosts'
debug3: expanded UserKnownHostsFile '~/.ssh/known_hosts2' -> '/Users/simon/.ssh/known_hosts2'
debug1: Authenticator provider $SSH_SK_PROVIDER did not resolve; disabling
debug3: channel_clear_timeouts: clearing
debug3: ssh_connect_direct: entering
debug1: Connecting to 192.168.50.61 [192.168.50.61] port 22.
debug3: set_sock_tos: set socket 3 IP_TOS 0x48

and it just hangs at the last line with no further output.
 
Looking at that trace there’s a couple of reports that it could be related to WiFi QoS, so you could try adding:

-o IPQoS=none

To the command..

Do you try via wired connection?
 
Rename your /etc/ssh/ssh_config file on the client to *.bak to see if that helps.

If it does, you make have something in there that’s not working…
 
Back
Top Bottom