How to backup and restore ssh keys on Linux
I just reloaded the OS on my little System76 box and I stumbled around a bit when trying to restore my ssh keys. Here is a note for myself but maybe it can help someone else too.
Backup
I've written about how I backup my computer and I include my ssh keys in this backup.
Restore
Copy all files from the previous ~/.ssh
directory to the new ~/.ssh
directory then execute the following commands:
chmod 400 ~/.ssh/id_rsa
chmod 400 ~/.ssh/id_ed25519
ssh-add
You're welcome future self.