Ssh “Write failed: Broken pipe”
0 Comments Published November 17th, 2012 in Errors, Linux, OSX, Unix Tags: broken pipe, error, Linux, OSX, putty, ssh, sshd, terminal, timeout, unix, write failed.
I started to get this error “Write failed: Broken pipe” when I was leaving the terminal alone.
Since plumbers are still expensive, despite the crisis, I decided to fix the pipe by myself.
Very easy, just add the following line to /etc/ssh/sshd_config:
ClientAliveInterval 60
This will send a “keep-alive” packet from the server to the terminal client every 60 seconds so that the connection doesn’t get dropped.
If you can’t fix it on the server, for example if you don’t have administrative rights, you can fix your client to send the “keep-alive” packet to the server every 60 seconds, adding this line to ~/.ssh/config
ServerAliveInterval 60
It’s also possible to specify the ServerAliveInterval at the ssh command line:
$ ssh -o ServerAliveInterval=60 user@sshserver
More info about ClientAliveInterval and ServerAliveInterval can be found typing at the command line:
$ man 5 sshd_config $ man 5 ssh_config $ man ssh
Another reference here.
Your pipes should be safe now, and the plumbers out of business.
Search
Calendar
| M | T | W | T | F | S | S |
|---|---|---|---|---|---|---|
| « Sep | Dec » | |||||
| 1 | 2 | 3 | 4 | |||
| 5 | 6 | 7 | 8 | 9 | 10 | 11 |
| 12 | 13 | 14 | 15 | 16 | 17 | 18 |
| 19 | 20 | 21 | 22 | 23 | 24 | 25 |
| 26 | 27 | 28 | 29 | 30 | ||
Follow me
Archives
Categories
- Android (3)
- Apple (29)
- Books (7)
- Eclipse (14)
- Errors (5)
- Firefox (7)
- Git (3)
- Hardware (18)
- Horror Code (8)
- Internet (21)
- Java (104)
- JavaScript (9)
- Life, universe and everything (45)
- Lifehacks (26)
- Linux (52)
- Opinions (26)
- OSX (11)
- OWNER API (2)
- Python (1)
- Software (33)
- Speeches and Conferences (8)
- Unix (5)
- Web (23)
- Windows (19)
Tag Cloud
Android apple architecture Bash configuration CSS Development Düsseldorf Eclipse Git Google Hardware hdr How-To howto Java JAXB job Karmic Linux lion MacBook music Open Source Opinion OSX os x patterns Pitfalls Practices Resume Security Software Suspend TDD Testing tip tonemapped Tricks Ubuntu unix video Web Workaround XML
WP Cumulus Flash tag cloud by Roy Tanck and Luke Morton requires Flash Player 9 or better.
Blog License
Blogs I like
Books on the desk
Friends' Blogs
- Antonio Terreno & Valter Bernardini
- Bruno Bossola
- Daniele Galluccio
- Domenico Ventura
- Ed Schepis
- Fabrizio Gianneschi
- Luca Grulla
- Luigi Zanderighi
- Marcello Teodori
- Mida Boghetich
- Muralidharan Chandrasekaran
- Piero Ricca
- Renzo Borgatti
- Simone Bordet
- Simone Bruno
- Uberto Barbini
- Valvolog
- Webtide blogs (Greg Wilkins & Jan Bartel)
Links



















No Responses to “Ssh “Write failed: Broken pipe””
Please Wait
Leave a Reply