Set an alias for SSH to access a remote server
Generally, the command used to access the remote server via ssh is: ssh username @ IP address,
For example, ssh [email protected], and then enter the password to access it.
Take Mac OS as an example. For other operating systems, search for them by directory.
The settings are as follows:
Use cd ~ /. Ssh/go to the ssh directory and you will see the config and known_hosts files. If there is no setting, there will only be known_hZ hosts? Http://www.bkjia.com/kf/ware/vc/ "target =" _ blank "class =" keylink "> vc3Rzo6y/examples/qGjPC9wPgoKPHA + yrnTw3ZpbbHgvK1jb25maWfOxLz + placement =" brush: SQL; ">Host jhdHostName 1xx. 1xx. 1xx. 67 User rootIdentitiesOnly yes
Where:
1. The Host is followed by a name, which can be accessed later;
2. HostName is your host IP address;
3. the User is the username used to log on to the host;
4. Inherent IdentitiesOnly yes configuration;
The setting is complete. Later, use ssh jhd and enter the password to log on to the remote host!