问题原文
原帖链接 · Pablo Pazos · CC BY-SA 4.0
I created a server, and configured SSH to not allow root login and disable password access, so only accepts an SSH key to login.
I have a machine A with a key, and I can access my server from that machine without any problems.
Also have a backup of those keys, just in case.
Let's say my machine A dies tomorrow and I got a new machine B, and of course need to access my server.
Here I don't know how things work. Should I just copy the keys from my backup to machine B and that will allow me to access my server? Or should the keys be imported via some OpenSSH command?
So my first doubt is about the backup import, because I'm afraid to completely lose access to my server.
The second is about the passphrase I set for my keys on machine A. Is that still valid for my copied keys? Or through the import I need to set a new passphrase on the new machine.
Thanks.
社区高分解答
原帖链接 · womble · CC BY-SA 4.0
Copying the backed-up keys into place will work fine. No specific import command is required. A passphrase is a property of a key file (specifically, it is the input to a key-derivation function to generate an encryption key for the private key data).
摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。
