SSH broken pipe on macOS Catalina
How to fix the broken pipe error when using SSH on macOS
After upgrading to macOS Catalina 10.15.3 last night, I noticed that I was no longer able to log in to my OVH Cloud instance, as well as Github using git
, but instead just got the error: packet_write_wait: connection to x.y.z. port 22: broken pipe
What was even weirder was that SSH to my internal machines did work without any issues.
So Google to the rescue! I spent a few hours looking around and ended coming across this post on VMWare's forums which described the exact same problem and proposed simple solution, just adding -o IPQoS=throughput
to your normal ssh command. So something like the following:
ssh -o IPQoS=throughput root@192.168.1.1
Don't forget, you can add the following to your ~/.ssh/config
so that you don’t have the use the -o flag every time as well as have any other command using SSH use that flag:
Host *
IPQoS=throughput