1:激活root账户sudo passwd root输入密码之后,切换到 root 账户。su root输入密码之后就可以进入 root 账户了。
2:安装 SSH 服务apt-get install ssh安装完成之后,可以使用命令启动 SSH 服务。有两种方式可以启动,下面两种方式任选其一。service sshd start或/etc/init.d/sshd start
3: 开启 SSH 的 root 账户远程登录用 Xshell root 连接时,显示 SSH 服务器拒绝了密码,原因是 sshd 默认设置不允许 root 用户密码远程登录。现在开启 root 账户远程登录。vi /etc/ssh/sshd_config找到# Authentication:PermitRootLogin prohibit-passwordStrictModes yes改为# Authentication:PermitRootLogin yesStrictModes yes此时重启 SSH 服务service sshd restart或/etc/init.d/sshd restart当然,重启电脑更好。
4: Enjoy尽情享受超级用户权限吧。Xshell 登录后的效果是这样的。
Xshell 4 (Build 0131)
Copyright (c) 2002-2014 NetSarang Computer, Inc. All rights reserved.
Type `help' to learn how to use Xshell prompt.
Xshell:\>
Connecting to 192.168.0.31:22...
Connection established.
To escape to
local
shell, press
'Ctrl+Alt+]'
.
The programs included with the Deepin GNU
/Linux
system are
free
software;
the exact distribution terms
for
each program are described
in
the
individual files
in
/usr/share/doc/
*
/copyright
.
Deepin GNU
/Linux
comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
root@hadoop-1:~
# ls
root@hadoop-1:~
#