0
点赞
收藏
分享

微信扫一扫

阿里云的堡垒机无法使用秘钥登录Ubuntu服务器

服务器是阿里云上的Ubuntu 22.04

堡垒机是用的阿里云提供的

秘钥对也是阿里云生成的

但是,堡垒机始终无法用秘钥登录该服务器,只能使用密码登录

查看日志/var/log/auth.log ,有如下提示

userauth_pubkey: key type ssh-rsa not in PubkeyAcceptedAlgorithms [preauth]

修改配置文件/etc/ssh/sshd_config,添加如下内容

PubkeyAcceptedKeyTypes=+ssh-rsa

重启sshd服务

尝试发现堡垒机可以使用秘钥登录服务器

阿里云的堡垒机无法使用秘钥登录Ubuntu服务器_堡垒机

举报

相关推荐

0 条评论