【问题标题】:vagrant ssh get error: ssh_exchange_identification: read: Connection reset by peervagrant ssh 获取错误:ssh_exchange_identification:读取:对等方重置连接
【发布时间】:2019-04-06 05:32:06
【问题描述】:

我正在安装 buildroot。但是当我从 buildroot doc 阅读手册时,发生了错误。

这是我的过程。

curl -O https://buildroot.org/downloads/Vagrantfile; vagrant up

结果如出一辙。

==> default: Attempting graceful shutdown of VM...
    default: Guest communication could not be established! This is usually because
    default: SSH is not running, the authentication information was changed,
    default: or some other networking issue. Vagrant will force halt, if
    default: capable.
==> default: Forcing shutdown of VM...
==> default: Checking if box 'ubuntu/bionic64' is up to date...
==> default: Clearing any previously set forwarded ports...
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
==> default: Forwarding ports...
    default: 22 (guest) => 2222 (host) (adapter 1)
==> default: Running 'pre-boot' VM customizations...
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2222
    default: SSH username: vagrant
    default: SSH auth method: private key

然后我尝试用 ssh 连接

vagrant ssh

但是有北向显示。就这样。

lt@ubuntu:~/qemu/buildroot$ vagrant ssh

所以我尝试使用 ssh 命令。

lt@ubuntu:~/qemu/buildroot$ vagrant ssh-config
Host default
  HostName 127.0.0.1
  User vagrant
  Port 2222
  UserKnownHostsFile /dev/null
  StrictHostKeyChecking no
  PasswordAuthentication no
  IdentityFile /home/lt/.vagrant.d/insecure_private_key
  IdentitiesOnly yes
  LogLevel FATAL

ssh vagrant@127.0.0.1 -p 2222 i /home/lt/.vagrant.d/insecure_private_key

不过,也北向显示。

你能给我打个招呼吗?谢谢。

【问题讨论】:

    标签: vagrant buildroot


    【解决方案1】:

    尝试执行以下命令:

    1. vagrant halt
    2. vagrant up
    3. vagrant ssh

    这应该可以解决问题。如果仍然存在,请检查您的 BIOS 设置以确保已启用虚拟化。如果您在 Windows 上,请确保 hyper-v 已禁用。

    【讨论】:

      【解决方案2】:

      这是一个重复的问题并多次回答

      你可以在这里参考我的回答https://stackoverflow.com/a/62928259/6150566

      【讨论】:

        【解决方案3】:

        如果您使用的是 Windows,请转到 BIOS 来启用虚拟化。 如果您在嵌套 VM 中运行 VirtualBox,则可以通过关闭 VM 来启用虚拟化设置 (VT-X)。

        【讨论】:

          猜你喜欢
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 2019-02-14
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 2015-05-15
          • 1970-01-01
          相关资源
          最近更新 更多