1

I've been researching this problem for the past 4-5 days, but to no avail. SSH refuses to log in from remote computer. Ubuntu 20.04 server is running on server on local network.

So far:

1. I'm able to ftp, ssh, telnet, vnc to a local server from computers on the same local network: no problem

2. From a remote location I'm able to ftp, telnet, vnc to local server but ssh refuses to connect to the server

3. more info:

  • modem forwards port 22 to local server (the same for ports 21 & 23 & 80 & ...)

  • sshd is up and running on the server

  • ufw configured to grant access to port 22: Action ALLOW IN from "Anywhere" (checked by issuing commands ufw status numbered and ufw status verbose).

  • service ufw status reports ufw is active

  • lsof i -n -P|grep LISTEN reports port 22 is listening

  • ssh -vvv IP_Address from remote computer reports this error message: async io completed with error: 10061" & connection fails

  • /var/log/auth.log logs the following item after connection refused: Received signal 15; terminating which means "some" process has issued a SIGALRM & kernel killed connection attempt

At this point, I believe "something" (in ssh configuration files or elsewhere) is blocking remote connections to ssh, but I don't know where to look at this point. Answers to this previously posted problem have resulted in "generic answers" with no meaningful answers.

karel
  • 114,770
pelletie
  • 11
  • 2
  • Three small questions: (0) Have you confirmed that your ISP is not blocking incoming traffic on port 22? (1) Can you SSH into the machine from another computer on the same network? (2) Is the SSH server running? – matigo Dec 01 '21 at 22:20
  • How are you specifying the server address when you try to ssh from outside the network? Is it by the IP address or domain name? If IP address, which one? Is your server at home or in a office? – user68186 Dec 01 '21 at 22:53
  • Is there anything in /etc/hosts.deny? – Doug Smythies Dec 01 '21 at 23:11
  • Good evening, 1) checked with ISP (Bell Canada): no ports being blocked (ports 21, 23, 80,... all work fine) 2) if you read my comment, as mentioned yes I'a able to ssh from another computer on local network 3) as mentioned in my post, sshd is running – pelletie Dec 03 '21 at 01:39
  • Second comment: to query server from remote computer I use public WAN address as reported by modem. Server is at home and try to access from remote locaton – pelletie Dec 03 '21 at 01:41
  • Third comment: nothing defined in /etc/hosts.deny (all lines commented "#"). /etc/hosts.allow has "ALL: 192.168.2.0/24" defined (local network); if I add "smb: 0.0.0.0" remote ssh login still blocked – pelletie Dec 03 '21 at 01:50
  • Re Third comment: as far as /etc/hosts.allow is concerned, if problem was related to this config file, would not be able to access local server from remote computer with ftp (port 21), telnet (port 23), http (port 80) so my conclusion is that the problem is specifically related to ssh and one of it's configuration file – pelletie Dec 03 '21 at 01:52

0 Answers0