Ubuntu 14.04 爲 root 賬號開啓 SSH 登陸

1. 修改 root 密碼ubuntu

sudo passwd root

2. 以其餘帳戶登陸,經過 sudo nano 修改 /etc/ssh/sshd_config :ssh

xxx@ubuntu14:~$ su - root
Password:
root@ubuntu14:~# vi /etc/ssh/sshd_config

3. 註釋掉 #PermitRootLogin without-password,添加 PermitRootLogin yespa

# Authentication:
LoginGraceTime 120
#PermitRootLogin without-password
PermitRootLogin yes
StrictModes yes

4. 重啓 ssh  服務rest

root@ubuntu14:~# sudo service ssh restart
ssh stop/waiting
ssh start/running, process 1499
root@ubuntu14:~#
相關文章
相關標籤/搜索