LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
Search this Thread
Old 11-29-2010, 11:49 PM   #1
shogun1234
Member
 
Registered: May 2004
Posts: 165

Rep: Reputation: 15
ssh Write failed: Broken pipe


My env is Debian squeeze with v2.6.32-5.686 kernel, and ssh 5.5p1 Debian 5+b1 openssl 0.9.8o. The os is installed on virtualbox 3.2.10

I keep getting `Write failed: Broken pipe' when logining to debian box. After searching on the internet, most people suggest change .ssh/config by adding ServerAliveInterval parameter. However, several values has been tested e.g. 30, 50, 120, but none of them prevent from this occurred again.

Is there any good way to test what might happen behind e.g. network, etc.? Or anything I can tune?

I appreciate any suggestions.
Thanks.
 
Old 11-30-2010, 05:59 PM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,155
Blog Entries: 54

Rep: Reputation: 2794Reputation: 2794Reputation: 2794Reputation: 2794Reputation: 2794Reputation: 2794Reputation: 2794Reputation: 2794Reputation: 2794Reputation: 2794Reputation: 2794
- In what way does your system and user setup differ from the standard? (In other words: what modifications did you make?)
- What does syslog (and wherever SSH is configured to log to) say around the time of the login?
- What does running your ssh session in verbose mode (add "-vvv") say? (Attach as plain text?)
 
Old 12-08-2010, 03:13 AM   #3
shogun1234
Member
 
Registered: May 2004
Posts: 165

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by unSpawn View Post
- In what way does your system and user setup differ from the standard? (In other words: what modifications did you make?)
- What does syslog (and wherever SSH is configured to log to) say around the time of the login?
- What does running your ssh session in verbose mode (add "-vvv") say? (Attach as plain text?)
The setting comes with a clean debian squeeze installation. The only change is the config in /etc/ssh/sshd_config where PermitRootLogin was changed from yes to no avoiding rkhunter reports warning.

In /var/log/syslog or /var/log/message I do not discover any ssh message reported; I open files content to read and use e.g. `grep -i ssh /var/log/message' or `grep -i ssh /var/log/syslog' do not show any ssh message. Maybe I may use the wrong key word. With which key word I need to check in the log file?

In /etc/ssh/sshd_config, the logging level is as below
Code:
SyslogFacility Auth
LogLevel Info
The client side running `ssh -vvv user@ssh_host' shows

Code:
OpenSSH_5.5p1 Debian-5+b1, OpenSSL 0.9.8o 01 Jun 2010
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Applying options for *
debug2: ssh_connect: needpriv 0
debug1: Connecting to ssh_host [aaa.bbb.ccc.ddd] port 22.
debug1: connect to address aaa.bbb.ccc.ddd port 22: Connection refused
ssh: connect to host aaa.bbb.ccc.ddd port 22: Connection refused
But the server executing `netstat -tulp' can see ssh port is opened.

Code:
tcp 0 0 *:ssh *:*  LISTEN pid_number/sshd
Also, after broken pipe occurs, unless to do reboot, the client can not get in even restarting sshd service e.g. `/etc/init.d/ssh restart'

What might be the root cause and how to fix it?
Thanks for the help.

Last edited by shogun1234; 12-08-2010 at 03:25 AM.
 
Old 12-08-2010, 09:33 PM   #4
shogun1234
Member
 
Registered: May 2004
Posts: 165

Original Poster
Rep: Reputation: 15
After searching on the internet, I came across to read this thread - http://serverfault.com/questions/207480, concerning massive packet lost.

I change /proc/sys/net/ipv4/conf/all/arp_filter value from 0 to 1; and the machine which suffers `broken pipes' looking ok at the moment, but I do not know if this solves my problem or not because I do not know how to check e.g. packets loss.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
bash scripting sending "cat: write error: Broken pipe," rojoblandino Linux - Server 8 04-23-2010 10:23 AM
'broken pipe' error when attempting to write to windows share bowens44 Linux - General 1 07-20-2009 05:43 AM
smb_mount: open session failed!: syserr = Broken pipe neoform Linux - Server 0 05-08-2009 08:38 PM
dpkg wont install kbuild (failed to write to pipe in copy) Daniel Baker Linux - Wireless Networking 6 09-06-2007 10:52 AM
Doom 3 demo: snd_pcm_writei failed: Broken pipe nikolaj Linux - Games 0 04-14-2005 12:00 PM


All times are GMT -5. The time now is 09:09 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration