zoukankan      html  css  js  c++  java
  • SecureCRT 连接Win10内置ubuntu问题及解决办法

    1: 输入hostname, username 后连接提示: ubuntu The remote system refused the connection.

      因为没有安装或启动 ssh.  使用命令 su root 切换至root用户.    使用命令 ps -e | grep ssh 查看是否启动 ssh.

     如没有返回 则尝试使用命令 sudo apt install openssh-server  尝试安装ssh. 

    如提示已安装,  使用命令 /etc/init.d/ssh start 启动ssh服务. 再次尝试连接   

    //相关命令 停止服务/etc/init.d/ssh stop    重启服务/etc/init.d/ssh restart

    2: could not load host key. 

     查了下大概是因为鉴证证书的问题  使用命令 ssh-keygen -A  生成key

    3: a public key file has not been specified for this session would you like to specify one now

    在SecureCRT sessions > properties > Connection > SSH2  取消勾选 PublicKey.

     

    4: Reason: Unable to authenticate using any of the configured authentication methods.

     修改sshd_config配置信息 vim /etc/ssh/sshd_config  配置项 PasswordAuthentication 值no改为yes  修改后 使用命令 /etc/init.d/ssh restart 重启ssh服务.

    附上 vim基本命令.

    ESC 退出编辑模式.        :w 保存文件但不退出vi

    :w! 强制保存,不退出vi        :wq 保存文件并退出vi 

    :wq! 强制保存文件并退出vi        :q 不保存文件 退出vi

    :q! 不保存文件 强制退出vi

    5: The server has disconnected with an error. Server message reads: A protocol error occurred. Change of username or service not allowed: (root,ssh-connection) -> (xxxxxx,ssh-connection)

    因为SecureCRT设置的用户名和登录时输入的用户名不一致,在SecureCRT sessions > properties > Connection > SSH2  username 修改一致即可.

    到此为止, 终于连接成功了. 学习的过程中有问题要擅于使用搜索引擎. windows10 内置的ubuntu问题太多,已放弃, 改用redhat7.6

  • 相关阅读:
    Easy Code 自定义的模板
    LINUX批量修改文件名
    解决FTP登录太慢
    linux 命令
    Linux rename命令
    MySQL字段重复出现多少次
    kafka安装
    Redis 5.0简单安装
    Tomcat常用配置
    jenkins安装和简单配置
  • 原文地址:https://www.cnblogs.com/levia/p/11360567.html
Copyright © 2011-2022 走看看