Re: problem on exceptional quit

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On 10/07/2015 07:33 PM, Hua Wang wrote:
I installed Centos 7 on my server a few months ago. While using ssh, there is always a strange message "Write failed: Broken pipe”.

That's very often a result of IP conflict. I'm assuming that you're connecting to an IPv4 address. If so, log in to your CentOS server and use arping to look for conflicts:

# arping -c 2 D -I em1 <your address>

1. Login via Mac, Windows, Linux systems from different computers.
2. Modify sshd_config on the server as suggested by many posts:
TCPKeepAlive yes
ClientAliveInterval 60

TCPKeepAlive is "yes" by default. ClientAliveInterval doesn't appear to be a valid setting. Either TCPKeepAlive or ServerAliveInterval could be useful if the problem were a stateful firewall which was dropping your connection from its state table, and then resetting the connection in response to a later packet from your client.

Since those don't help, that tends to suggest that the problem isn't an intermediate host, but the server itself. Possibly an IP conflict. Also, check the output of "dmesg" to see if there are any problems recorded with the NIC. Check the output of "ifconfig" to see if there are TX or RX errors that increase when your connections are reset.

3. Modify ~/.ssh/config file on my local computer:
Host *
ServerAliveInterval 60
4. Login ssh using -Y instead of -X.

You didn't say what client OS you're using, but Fedora and CentOS set ForwardX11Trusted to "yes" by default, so "ssh -Y" is the same as "ssh -X". And even if it weren't, it wouldn't cause the problem you're seeing.

5. add ‘unset autologout’ in my .cshrc.

The error you're seeing won't be triggered by your shell exiting.

6. I checked IP address with the internet administrator, and it works well.
7. add a file named autologout.csh with ‘set autologout=0’.


_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
https://lists.centos.org/mailman/listinfo/centos




[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux