I generated an ssh key through digital ocean and used putty gen for a private key, when trying to open it through putty following the tutorial this error appears: no supported authentication methods available ( server sent: publickey )
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
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.
Click below to sign up and get $200 of credit to try our products over 60 days!
The error message you provided indicates that the server is expecting a public key for authentication, but it’s not being provided or recognized correctly. Here are a few steps to troubleshoot this issue:
Double-check your private key file: Make sure you have the correct private key file generated using PuTTYgen. The file should have a
.ppkextension, which is the format PuTTY uses for private keys.
Verify the public key on the server: Ensure that the public key counterpart of the private key you have is added to the
~/.ssh/authorized_keysfile on your DigitalOcean server. You can do this by logging in to the DigitalOcean dashboard and checking the SSH keys section.
Configure PuTTY correctly: When setting up your PuTTY session, ensure that you have provided the correct private key file. You can do this by navigating to Connection > SSH > Auth in the PuTTY configuration window and browsing to your
.ppkfile in the “Private key file for authentication” section.
Configure FileZilla correctly: To set up FileZilla for public key authentication, follow these steps:
a. Open FileZilla and go to Edit > Settings. b. In the settings window, navigate to Connection > SFTP. c. Click the “Add key file…” button and browse to your
.ppkfile. d. Save your settings and try connecting to your server again. You can follow the steps here as well:
Try accessing your Droplet via the Web console and make sure that your SSH key is actually added to the
/root/.ssh/authorized_keysfile. You can follow the steps here on how to recover from a lost SSH key if needed:
Hope that this helps!
Could not connect to server