In linux, how can I avoid password prompts when using the remote Copy command scp?
Source: Internet
Author: User
In linux, if you use the remote Copy command scp, how can I avoid the password prompt-Linux Enterprise Application-Linux server application information? For details, see the following. Write the ssh public key file of your local host user to the remote host user ~ /. Ssh/authorized_keys file, the specific method
Assume that the local host test1 and remote host test2
1. users in the test1 host
Run ssh-keygen-t rsa
The result is as follows:
Generating public/private rsa key pair.
Enter file in which to save the key (/home/. username/ssh/id_rsa): # Press Enter
Enter passphrase (empty for no passphrase): # Press Enter
Enter same passphrase again: # Press Enter
Your identification has been saved in/home/. username/. ssh/id_rsa.
Your public key has been saved in/home/. username/. ssh/id_rsa.pub.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.