Xshell鏈接Ubuntu時提示ssh服務器拒絕了密碼

今天Ubuntu添加root用戶後,xshell使用root用戶鏈接Ubuntu服務器提示拒絕了密碼

查找方法後在Ubuntu系統中修改:vi /etc/ssh/sshd_config
在文件中找到下方信息:
# Authenticaton
LoginGraceTime 120
PremitRootLogin without passwd
StrictModes yes
內容修改成:
# Authenticaton
LoginGraceTime 120
PremitRootLogin yes    # 看修改成「yes」
StrictModes yes
重啓ssh服務:/etc/init.d/ssh restart       # 使用root用戶遠程登陸則登陸成功shell

相關文章
相關標籤/搜索