Report this

What is the reason for this report?

Can I re-use SSH keys?

Posted on June 6, 2013

I just created a droplet for the first time (and this is my first time with any server). I’m now on the SSH keys page https://www.digitalocean.com/ssh_keys, where the first instruction tells us to check if SSH keys exist, and then it gives instructions for generating new SSH keys. In my case, using the command that the instructions gave, I discovered that I already have SSH keys (which I’m guessing I generated when I signed up for github or heroku)

Questions

  1. Should I reuse this SSH keys or generate new keys?

  2. The instructions talk about adding SSH keys to digital ocean and then creating a server. In my case, I created the droplet before adding SSH keys. Will this create any kind of problem I should be aware of?



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.
  1. If you can’t recall where the keys came from, you should create a new pair. The SSH key replaces the password of the selected account so the private key is top secret. You should also create the keys on your local computer to make sure the private key isn’t sent over the internet. <br> <br>There’s a nice tutorial: http://katsande.com/using-puttygen-to-generate-ssh-private-public-keys (I used 4096 bits instead of 2048). <br> <br>2) As far as I remember, adding a new Key does nothing to your current droplets. It only adds the option to add them to new ones. To use your key on an existing droplet you have to add the public key manually to ~/.ssh/authorized_keys

I can confirm LazyTiger’s second point. Adding keys to your DO account doesn’t touch any extant droplet.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.