Changing SSH port in sshd config file causes Putty and Filezilla not to function

Posted September 7, 2014 3.2k views

I’ve been successfully communicating with my droplet using encypted keys for some time. In order to improve security I changed the ssh port from the standard 22 to a different port number. Now I can’t access my droplet via Putty or Filezilla.
I did a restart of sshd and I modified Putty by changing the port there as well.( Filezilla says it gets the port from the server). Any idea what may be wrong ?

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Submit an Answer
1 answer

sounds like a firewall issue.

try running:

iptables -L

and drop it here, to be sure of that, you con log in using the digital ocean control panel, and inside of your box, just try “ssh localhost -p <PORT>” if it connects, it surely is a firewall issue.

  • @jsanchez
    Hi, thanks for the reply. I suspected it was a firewall problem. However, I have Fail2Ban installed and that program seems to take over the firewall. The command iptables -L shows no port numbers, only names ie. ssh.,smpt etc.
    I ran the command you suggested in the DO Console. What it did was to permanently add <PORT> (RSA) to the list of known hosts. I then tried to log in again with Putty and failed via connection timeout.
    I may have to dig around in Fail2Ban config files for some clues.