Use Putty to connect to the Centos Server
PS: the client has many methods to connect to the server, usually in the C/S mode.
Common server connection methods include:
1. Log On with the user name and password. The security level is very low.
2. Modify the port (set the default port 22 to another port) to log on. The security level is very low.
3. Set a complex password for Logon at the bottom of the security level.
4. log on to the server with the key, with the highest security level.
I. The following describes how to use putty to log on to the Centos Server:
Download the Putty tool or CRT. I am used to using putty. Then open the puttygen tool.
Use the puttygen tool to generate a key pair (when a key is generated, you will be prompted to slide the mouse to generate the key)
Save the generated public key and private key in a directory. (If the private key is lost, the server cannot log on. Remember !!)
2. perform the following operations on the server:
1. yum-y install openssh-server openssh-clients
2. The server generates a key pair ssh-keygen-t rsa
3. After the key is generated, there will be a. ssh directory with the public key (. pub) and private key of the server to facilitate jump to other servers.
4. Create the authorized_keys file under the. ssh directory, and then import the public key of the client to the authorized_keys file. The following is the public key of the client.
5. Authorize/root/. ssh/directory permissions
Chmod 700/root/. ssh/
6. Modify the/etc/ssh/sshd_config configuration file on the server (back up the file first, and then modify it !!!), Enable key authentication !!
7. restart ssh service sshd restart or/etc/init. d/sshd restart
Verification:
Client Logon
Set the key
OK operation completed ~~