I have set up public key authentication before and never had this much trouble… I am not sure what I am missing, but I have done all of the following:
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!
Ok… apparently it was an issue with copying the file over a remote connection.
I ran dos2unix on my id_rsa.pub, then cleared out authorized_keys and then cat id_rsa.pub >> authorized_keys…
boom, it works. Thanks to DEBUG3. (Why doesn’t verbose give key failure information…?)
I also had this same issue.
I solved it by
authorized_keys file” into a new pub_key.txt file locallyauthorized_keys file via rm authorized_keyssudo apt-get dos2unix (I’m running Ubuntu)dos2unix pub_key.txtauthorized_keys via cat pub_key.txt >> authorized_keysThis finally allowed me to putty into my box as all the tutorials described.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.