通常为了使用方便,我们把当前用户的权限设置为root,但在使用ssh localhost命令时,会出现认证失败的提示,sshd_config文件内容也进行了相应修改没用,后来尝试修改了一下root密码,没想到OK了。
root@chiminh-ubt:~# passwd root
输入新的 UNIX 密码:
重新输入新的 UNIX 密码:
passwd:已成功更新密码
root@chiminh-ubt:~# ssh localhost
root@localhost's password:
Linux chiminh-ubt 2.6.32-21-generic #32-Ubuntu SMP Fri Apr 16 08:10:02 UTC 2010 i686 GNU/Linux
Ubuntu 10.04 LTS
Welcome to Ubuntu!
* Documentation: https://help.ubuntu.com/
546 packages can be updated.
322 updates are security updates.
The programs included with the Ubuntu system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.
Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by
applicable law.
root@chiminh-ubt:~#