K
K
kambl42014-09-25 14:12:27
SSH
kambl4, 2014-09-25 14:12:27

Ping works, ssh crashes on timeout. How to decide?

Guys!!!
From a server with Ubuntu 14.04 ping to server 192.168.1.13 works, but when I try to connect via ssh I see this:

[email protected]:~# ssh -vvv 192.168.1.13
OpenSSH_6.6.1, OpenSSL 1.0.1f 6 Jan 2014
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug2: ssh_connect: needpriv 0
debug1: Connecting to 192.168.1.13 [192.168.1.13] port 22.

And it hangs, while everything connects normally from a computer with Windows or OS X ...
The problem is not only in ssh, but other open ports are not available.
nmap from the same Ubuntu machine:
[email protected]:~# nmap -PN 192.168.1.13

Starting Nmap 6.40 ( http://nmap.org ) at 2014-09-25 12:54 MSK
Nmap scan report for 192.168.1.13
Host is up (0.000085s latency).
Not shown: 996 closed ports
PORT     STATE SERVICE
22/tcp   open  ssh
80/tcp   open  http
8000/tcp open  http-alt
8080/tcp open  http-proxy

[email protected]:~# telnet 192.168.1.13 80
Trying 192.168.1.13...
^C
[email protected]:~# telnet 192.168.1.13 8000
Trying 192.168.1.13...
^C
[email protected]:~# telnet 192.168.1.13 8080
Trying 192.168.1.13...

gentoo is installed on server 192.168.1.13, firewall is disabled.
If you need to explain something in more detail, I will only be happy.
Thanks a lot :)

Answer the question

In order to leave comments, you need to log in

1 answer(s)
I
Igor, 2014-09-25
@merryjane

On the dst server, check that port 22 is indeed not closed:

iptables-save
ip6tables-save

Check tcp-wrapper:
cat /etc/hosts.allow
cat /etc/hosts.deny

Check if the connection is closed in the daemon itself:
cat /etc/ssh/sshd_config

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question