I am trying to change my EC2 public key for myself, the rest of my team that uses AWS, and also to run instances.
So the old key was (for example) "my_key", and I created a new key called "my_key2".
I made a new key, saved the .pem file along with the old one, so both "my_key.pem" and "my_key2.pem" are in my ~ / .ssh folder.
Now I try to use ssh in other instances to change their authorization_keys to public key sharing, but when I try ssh, I get
amy$ ssh ***-**-**-***-***.foo.com Permission denied (publickey).
I tried to extract the new file "my_key2" from the .ssh folder, and the same problem occurs. I did not have this problem before I started to cheat. Any tips on getting ssh to recognize my old certificates so that I can get everyone to switch to new keys?
Amy m source share