ssh登陆免密

 

  1. 使用ssh-keygen生成 SSH 公钥文件
  2. 在~/.ssh/config 文件中加入
    Host xxx
    
        HostName xxx.xx.xxx.xx
    
        User xxxx
    
        IdentityFile ~/.ssh/id_rsa
  3. 使用 ssh-copy-id xxx 将公钥上传到服务器
Smilie Vote is loading.
✿ 阅读数:1,918  分类:文章

发表评论

邮箱地址不会被公开。 必填项已用*标注

Captcha Code