SSH connectivity between two machines with private key

Hi

I have two machines Mac1 and Mac2 logging in with same user id and same private key.

can anyone let me know how to connect these two machine using ssh .
or SCP files to other machine

:wall:

As I understand it, private keys should be specific to one machine.

But apart from that, when you create a private key, a public key counterpart is also created. In order to use the keys to connect transparently with ssh, you need to transfer those public keys to the machine you want to connect from, and add them to the file authorized_keys (for example with "cat pub_key.oub >> authorized_keys").