• 使用Xshell 5工具连接Ubuntu18服务器


    1.安装SSH

    打开终端窗口,输入命令

    sudo apt-get install openssh-server
    

     等待安装完成

    2.查看SSH服务是否启动

    输入命令

    sudo ps -e |grep ssh  

     看到SSHD则说明服务已经启动,如下图

    如果没有启动,输入命令

    sudo service ssh start
    

    3.修改配置文件

    输入命令

    sudo gedit /etc/ssh/sshd_config
    

    把配置文件中的"PermitRootLogin without-password"加一个"#"号注释掉,再增加一句"PermitRootLogin yes",保存文件,如下图。这样做是为了允许root用户登录。

    或者直接把下面的内容复制到配置文件中

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

    4.重新启动

    /etc/init.d/ssh restart
    

    5.查看ip地址  

    ifconfig
    

    6.安装Xshell 5

    7.连接

    root用户

  • 相关阅读:
    Oracle数据库
    Python-aiohttp百万并发
    Sentry的安装搭建与使用
    traceroute命令初探
    Python中断言与异常的区别
    二十三种设计模式及其python实现
    Celery
    SQLAlchemy
    python里使用reduce()函数
    python实现栈
  • 原文地址:https://www.cnblogs.com/jcjssl/p/9375156.html
Copyright © 2020-2023  润新知