How to get a second copy of ssh keys

sammyboy123 51 Reputation points
2021-01-07T16:29:23.71+00:00

I have an azure linux VM and had a pair of keys. Those keys are on a seperate computer than the one I ussually use. How do I get a second copy of the keys?

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
0 comments No comments
{count} votes

Answer accepted by question author
  1. Andriy Bilous 12,076 Reputation points MVP Volunteer Moderator
    2021-01-07T18:03:23.567+00:00

    Hello @sammyboy123
    Unfortunately you cannot get a copy of the private key if it is lost for example.
    https://serverfault.com/questions/183664/recover-an-ssh-private-key

    Concept of SSH-keys is described here
    https://www.ssh.com/ssh/key/

    You can only regenerate new key pair(private and public keys) and reset SSH configuration on Linux VM with new public key

    54541-image.png

    https://learn.microsoft.com/en-us/azure/virtual-machines/troubleshooting/troubleshoot-ssh-connection

    There is a possibility to store SSH keys in Azure Portal, so you can downloaded it on any of your local machines.
    https://learn.microsoft.com/en-us/azure/virtual-machines/ssh-keys-portal

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.