Web Admin Blog Real Web Admins. Real World Experience.

20May/150

SSH on a Mac Errors with “Write Failed: Broken Pipe”

Recently I had an issue when moving to a new Mac on OSX when I was trying to SSH to a Linux server.  It would make the initial connection and then prompt me for a password.  Once I entered the password, however, it would just hang (ctrl+c wouldn't even escape out) until eventually it would break to the command line with the message "Write Failed: Broken Pipe".  After digging through various posts online, most of which were referring to timing out due to inactivity, I finally found a winner.  I edited the /etc/sshd_config file and set the ClientAliveInterval value to 300.  Then, I rebooted my Mac.  The next time I tried to SSH to the same server, everything connected as expected.  I hope this helps someone else in the future who is running up against the same issue I had.