VirtualBox5.02でvagrantやろうとしてハマったのでメモ

  • 37
    Like
  • 4
    Comment
More than 1 year has passed since last update.

vagrint初挑戦でハマったのでメモ。

結果的には、VirtualBox 5.02のバグっぽい。

症状

vagrant upのログ

$ vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> 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 => 2222 (adapter 1)
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
The guest machine entered an invalid state while waiting for it
to boot. Valid states are 'starting, running'. The machine is in the
'poweroff' state. Please verify everything is configured
properly and try again.

If the provider you're using has a GUI that comes with it,
it is often helpful to open that and watch the machine, since the
GUI often has more helpful error messages than Vagrant can retrieve.
For example, if you're using VirtualBox, run `vagrant up` while the
VirtualBox GUI is open.

The primary issue for this error is that the provider you're using
is not properly configured. This is very rarely a Vagrant issue.

VirtualBoxのエラー情報

Failed to load VMMR0.r0 (VERR_VMM_SMAP_BUT_AC_CLEAR).
終了コード : NS_ERROR_FAILURE (0x80004005)
コンポーネント: ConsoleWrap
インターフェース: IConsole {872da645-4a9b-1727-bee2-5585105b9eed}

原因

おそらくこれ
https://www.virtualbox.org/ticket/14412

対応方法

古いバージョンにインストールしなおし。探すのに苦労したが、
https://www.virtualbox.org/wiki/Download_Old_Builds
にあっった。
5.0でも大丈夫なのかもしれないが、5系自体が信じられなくなったので4.3を入れたら直った。