Can I have multiple ssh keys in my .ssh folder?
Problem
Can I create multiple ssh keys, and rename them to user friendly names so I know which key is for which website etc. Is this safe? e.g: How will it know which key to check against when connecting? On my computer now, when I look at known_hosts, they all seem to have the same key after the name of the host??
Error Output
github_id_rsa github_id_rsa.pub .. ...
Unverified for your environment
Select your OS to check compatibility.
1 Fix
Fix for: Can I have multiple ssh keys in my .ssh folder?
You can modify the file ~/.ssh/config to use different identity file for different servers. Edit the ~/.ssh/config in your favorite editor and add an entry that is appropriate for your situation like so: The first part above sets the defaults for all hosts and the other sections overrides what should be used for each of the hosts matching the patterns. If you have a different username for each of the hosts, then you can add a User key followed by the username on the remote to the section.
Awaiting Verification
Be the first to verify this fix
Sign in to verify this fix