0

I found quite a few posts about migrating ssh keys to a new host, but couldn't find much about migrating from one user to another on the same host...

We are migrating a NAS share to a new platform, and in the process are introducing new generic application IDs. I have been asked to copy the ssh keys from the existing generic ID to the new one. The ID will be accessing the same hosts from the same hosts, but it will be using the new ID. What is the best practice for copying the keys so that our 100+ applications that can use this ID will not run into the whole "add this key (yes/no)" question which would cause a massive number of failures?

Tim S.
  • 147

2 Answers2

1

In addition to copying the keys, copy the ~/.ssh/known_hosts file, which contains identification fingerprints for all hosts to which the user has connected. If needed, you can also use the file /etc/ssh/ssh_known_hosts if you want to seed all users on a given system with pre-validated host keys.

-1

Is this what you want?

https://superuser.com/a/125326/417776

Use the -o option,

ssh -o "StrictHostKeyChecking no" user@host
YuMS
  • 1