Hello experts,
OS : CentOS
Could you please help me with the following scenario :
I wish to use scp command in order to copy a file (say : f1.txt) from server 2 to server 1.
Both servers have a common user (say : user1) configured. Also, the file is owned by the same user on both servers.
Could you please provide the command for the same such that whenever the scp command is executed, then the prompt for password is skipped.
scp code being used :
scp user2@server2:f1.txt /some/local/directory
Limitations :
- No changes in any system file(s).
- No scripts to be used.
- No use of
ssh keygen
. - No use of
sshpass
command
Regards,
Haider