Reference: http://www.cnblogs.com/rooney/archive/2012/03/22/2411727.html
1. Generate the login public key and Private Key
First, use the ssh-keygen command line to generate a pair of public and private keys, and send the public key to the server for configuration.
Some applications directly use the private key in the putty format. You can use puttygen to convert the Private Key to the putty format (for example, git GUI needs to use this ).
2. About the configuration file
After OpenSSH is installed on Linux, you can use the SSH command line to connect to it. It is more convenient to configure the user name and private key.
1) copy/etc/ssh/ssh_config ~ /. Ssh/config (Rename to config)
2) modify the host * Project (indicating that all hosts connected by default use this configuration. You can add a dedicated host configuration) and add
Identityfile ~ /. Ssh/id_rsa/xxx. RSA private key storage directory
User XXX login Username
If both are correctly configured, you can directly connect to SSH 10.0.0.1!