ssh登录到linux提示Permission denied, please try again.

远程ssh到linux系统突然提示Permission denied, please try again,再三确认密码正确依然上不去。

找了很多资料都是sshd的配置文件/etc/ssh/sshd_config

修改如下:(原配置文件取消注释掉)

PermitRootLogin yes 

修改后发现还是登录不上,再仔细查看配置文件,如下:

需要把PermitRootLogin yes 注释掉;

[root@nginx01 .ssh]# vi /etc/ssh/sshd_config 

#######################################################################
#                    ! ! ! ! ! IMPORTANT ! ! ! ! !                    #
# * Your system has detected a weak password for root account and for #
# security reasons, remote access via SSH has been blocked to prevent #
# unauthorized access. In order to enable again remote access to this #
# machine for root user via SSH, set a new complex password for root  #
# account and delete 'DenyUsers root' line below on this config file. #
# * Restarting the SSH Daemon is required for changes to take effect. #
#                                                                     #
# Bash commands:                                                      #
# passwd root             (Changes your root password).               #
# service sshd restart    (Restart the SSH Daemon).                   #
#DenyUsers root
#######################################################################

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值