Use ssh-keygen to set ssh password-less login

Source: Internet
Author: User
Ssh is a protocol designed for the security of remote logon sessions and other network services. By default, password authentication is required for ssh connections.

Ssh is a protocol designed for the security of remote logon sessions and other network services. By default, ssh connections require password authentication. you can add system authentication (public key-private key) modifications. after modification, inter-system switching can avoid password input and ssh authentication. The following describes the creation process.

First, check whether there is a public key;

If not, create

Create an ssh public key

Then copy the public key to the managed machine.

[W @ w. ssh] # scp id_rsa.pub root@192.168.xxx.xxx :~ /. Ssh/authorized_keys

Access

# Ssh 192.168.xxx.xxx
The authenticity of host' (<192.168.xx.xxx>) 'Can't be established.
RSA key fingerprint is 34: b9: 92: 06: 53: e6: 91: 4d: 47: 92: 73: 57: 78: 6a: 5d: 09.
Are you sure you want to continue connecting (yes/no )? Yes
Warning: Permanently added' (<192.168.xxx.xxx> '(RSA) to the list of known hosts.

This is because after the first access, ssh will save the authenticated host information in. ssh/known_hosts:

192.168.xxx.xxx ssh-rsa protocol + protocol/RxkB/protocol + YElCgH + protocol/8ULgaKg3LtvP + protocol/p0ml + uuS4DO3Up2VjqoRtqtuzWExnTyAGS/Signature/YLTGF8vVvjo5w =

5. access again. you can log on via ssh without a password.

[Root @ localhost. ssh] # ssh 192.168.36.194
Last login: Fri Apr 22 00:56:45 2011 from 192.168.18.44

Related Article

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.