Linux免密配置

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
[root@oracle11g ~]# ssh-keygen
Generating public/private rsa key pair.
Enter file in which to save the key (/root/.ssh/id_rsa):
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /root/.ssh/id_rsa.
Your public key has been saved in /root/.ssh/id_rsa.pub.
The key fingerprint is:
ef:8f:09:3d:77:6b:bd:74:99:2b:ba:2e:5b:18:21:d8 root@oracle11g
The key's randomart image is:
+--[ RSA 2048]----+
|                 |
|      o          |
|     . E .       |
|        . .      |
|        S.       |
|         oo     o|
|        ..+.. .=.|
|         +.= oo.+|
|         .B=+.oo.|
+-----------------+
[root@oracle11g ~]#
[root@oracle11g ~]#
[root@oracle11g ~]#
[root@oracle11g ~]# cd .ssh/
[root@oracle11g .ssh]# ls
authorized_keys  id_rsa  id_rsa.pub  known_hosts
[root@oracle11g .ssh]#
[root@oracle11g .ssh]#
[root@oracle11g .ssh]#
[root@oracle11g .ssh]# ssh-copy-id -i root@192.168.162.199
root@192.168.162.199's password:
Now try logging into the machine, with "ssh 'root@192.168.162.199'", and check in:
 
  .ssh/authorized_keys
 
to make sure we haven't added extra keys that you weren't expecting.
 
[root@oracle11g .ssh]#
[root@oracle11g .ssh]#
[root@oracle11g .ssh]#
[root@oracle11g .ssh]# ssh 192.168.162.199
Last login: Fri Jun 17 18:29:42 2022 from oracle11g
[root@node01 ~]#

  

posted @   orcl  阅读(43)  评论(0编辑  收藏  举报
相关博文:
阅读排行:
· 阿里最新开源QwQ-32B,效果媲美deepseek-r1满血版,部署成本又又又降低了!
· AI编程工具终极对决:字节Trae VS Cursor,谁才是开发者新宠?
· 开源Multi-agent AI智能体框架aevatar.ai,欢迎大家贡献代码
· Manus重磅发布:全球首款通用AI代理技术深度解析与实战指南
· 被坑几百块钱后,我竟然真的恢复了删除的微信聊天记录!
历史上的今天:
2020-06-17 Linux下网卡配置多个IP
2020-06-17 mycat启动失败
点击右上角即可分享
微信分享提示