LoginSignup
0
0

More than 3 years have passed since last update.

【Vagrant】vagrant upすると「SSH auth method: private key」で止まってタイムアウトする

Last updated at Posted at 2021-04-26

vagrant upでちゃんと起動しなかった

久しぶりにVM環境を立ち上げるためにvagrant upしたら以下のようなエラーが発生

C:\work\centos>vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Checking if box 'centos/7' version '2004.01' is up to date...
~
    default: SSH username: vagrant
==> default: SSH auth method: private key
Timed out while waiting for the machine to boot. This means that
Vagrant was unable to communicate with the guest machine within
the configured ("config.vm.boot_timeout" value) time period.

If you look above, you should be able to see the error(s) that
Vagrant had when attempting to connect to the machine. These errors
are usually good hints as to what may be wrong.

If you're using a custom box, make sure that networking is properly
working and you're able to connect to the machine. It is a common
problem that networking isn't setup properly in these boxes.
Verify that authentication configurations are also setup properly,
as well.

If the box appears to be booting properly, you may want to increase
the timeout ("config.vm.boot_timeout") value.

SSH認証のとこでエラーが発生してるぽい

原因

Hyper-Vがオンの状態で起動しようとしてたのが原因でした。
Docker使うために一時的にHyper-Vを切り替えたのが原因だったので、オフにして再起動後vagrant upすると何事もなかったかのように起動しました。

おわり

  • 同じエラーで他によくある原因としてはVMのネットワークの設定がおかしいとかあるみたいでした(自分は違いましたが)

参考URL

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0