Wordpress/Ubuntu server: Unable to SSH or SFTP, keeps getting blocked

June 10, 2017 2.1k views
One-Click Install Apps Linux Commands WordPress Configuration Management Ubuntu

Hi I have a Wordpress blog hosted on Digital Ocean (using 1-click install, Ubuntu Wordpress 4.7 on 16.04). I have ufw and fail2ban installed on this server, and I’m wondering if they’re causing the issue.

I’m trying to ssh into the server using root user, or even FileZilla into it but can’t seem to get through. Keeps saying permission denied.

Please help, thanks!

2 Answers

Hi @sayemmkhan

If you get a “permission denied”, then it’s because the password or SSH key is not valid.

If the firewall (or fail2ban) was blocking you, then you would get a “could not connect”.

Did you setup the droplet with SSH key or did you receive a password, when you created the droplet?
You can reset the password via the control panel. If you used a SSH key, then you need to start the server with a Recovery Image, which only Support can activate for you.

@hansen I’m not even able to get to the password prompt when I try sshing into it, this is the output:

➜ Desktop ssh root@softwareentrepreneuradvice.com
The authenticity of host ‘softwareentrepreneuradvice.com (’ can’t be established.
ECDSA key fingerprint is SHA256:6X0pIZ9VhP410MmdyjAFcvld5WXky/Ju408zM0wnsn4.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'softwareentrepreneuradvice.com,’ (ECDSA) to the list of known hosts.
Permission denied (publickey).

A developer on my team created this droplet few days ago, so not sure why I’m not able to ssh root into it.

If I’m not getting the password prompt, then it was probably created with SSH key like you say?

  • @sayemmkhan
    Yes, it has been setup with a key, so unless you have the private key that the developer used, then you cannot connect and have two options; get the key from the developer or ask Support to restart the server with Recovery Image to be able to reset access.

Have another answer? Share your knowledge.