ubuntu下允许root用户ssh远程登录

 (2011-07-22 10:19:42)

http://www.360doc.com/content/14/0601/12/7385274_382738147.shtml

SSH服务器,可以通过SSH协议来访问远程服务器,代替telnet和ftp。但是ubuntu默认是不启用root用户也不允许root远程登录的。所以需要先启用root用户

启用root用户:sudo passwd root      //修改密码后就启用了。

安装OpenSSH server:

1. 使用apt命令安装openssh server

$ sudo apt-get install openssh-server

2. 可以对 openssh server进行配置

$ sudo vi /etc/ssh/sshd_config

找到PermitRootLogin no一行,改为PermitRootLogin yes

3. 重启 openssh server

$ sudo service ssh restart

4. 客户端如果是ubuntu的话,则已经安装好ssh client,可以用下面的命令连接远程服务器。

$ ssh xxx.xxx.xxx.xxx

如果是windows系统的话,可以使用SSH Secure Shell等ssh软件进行远程连接。

相关文章:

  • 2022-12-23
  • 2021-11-20
  • 2021-06-17
  • 2021-04-16
  • 2021-08-18
  • 2022-12-23
  • 2022-12-23
  • 2021-11-02
猜你喜欢
  • 2022-12-23
  • 2021-06-24
  • 2021-12-04
  • 2022-12-23
  • 2022-01-08
  • 2021-12-31
  • 2021-04-09
相关资源
相似解决方案