Packer build fails on VBoxManage error: VBoxManage: error: VT-x is not available (VERR_VMX_NO_VMX)

henryfbp's Avatar

henryfbp

16 Mar, 2019 02:10 AM

The image for AppVeyor is Ubuntu1804.

Repo is at https://github.com/HenryFBP/2019-team-07f-mirror (Note: The odd name is because the main repository is private.)

The build fails because VT-x is not enabled on the machine I'm running packer build ... on.

Is there an image that has VT-x enabled or any other way around this short of using Docker to build images?

Thanks!

==> virtualbox-iso: Starting HTTP server on port 8319
==> virtualbox-iso: Creating virtual machine...
==> virtualbox-iso: Creating hard drive...
==> virtualbox-iso: Creating forwarded port mapping for communicator (SSH, WinRM, etc) (host port 2342)
==> virtualbox-iso: Executing custom VBoxManage commands...
    virtualbox-iso: Executing: modifyvm packer-ubuntu-16.04.6-amd64_mysql --memory 4096
    virtualbox-iso: Executing: modifyvm packer-ubuntu-16.04.6-amd64_mysql --cpus 4
==> virtualbox-iso: Starting the virtual machine...
    virtualbox-iso: The VM will be run headless, without a GUI. If you want to
    virtualbox-iso: view the screen of the VM, connect via VRDP without a password to
    virtualbox-iso: rdp://127.0.0.1:5916
==> virtualbox-iso: Error starting VM: VBoxManage error: VBoxManage: error: VT-x is not available (VERR_VMX_NO_VMX)
==> virtualbox-iso: VBoxManage: error: Details: code NS_ERROR_FAILURE (0x80004005), component ConsoleWrap, interface IConsole
==> virtualbox-iso: Deregistering and deleting VM...
==> virtualbox-iso: Deleting output directory...
Build 'virtualbox-iso' errored: Error starting VM: VBoxManage error: VBoxManage: error: VT-x is not available (VERR_VMX_NO_VMX)
VBoxManage: error: Details: code NS_ERROR_FAILURE (0x80004005), component ConsoleWrap, interface IConsole
==> Some builds didn't complete successfully and had errors:
--> virtualbox-iso: Error starting VM: VBoxManage error: VBoxManage: error: VT-x is not available (VERR_VMX_NO_VMX)
VBoxManage: error: Details: code NS_ERROR_FAILURE (0x80004005), component ConsoleWrap, interface IConsole
==> Builds finished but no artifacts were created.
Command exited with code 1
Build failed
  1. 1 Posted by henryfbp on 16 Mar, 2019 06:15 AM

    henryfbp's Avatar

    Update: Windows box returns the SAME error!

    
        virtualbox-iso: Transferred: http://releases.ubuntu.com/16.04/ubuntu-16.04.6-server-amd64.iso
    ==> virtualbox-iso: Starting HTTP server on port 8662
    ==> virtualbox-iso: Creating virtual machine...
    ==> virtualbox-iso: Creating hard drive...
    ==> virtualbox-iso: Creating forwarded port mapping for communicator (SSH, WinRM, etc) (host port 2720)
    ==> virtualbox-iso: Executing custom VBoxManage commands...
        virtualbox-iso: Executing: modifyvm packer-ubuntu-16.04.6-amd64_mysql --memory 4096
        virtualbox-iso: Executing: modifyvm packer-ubuntu-16.04.6-amd64_mysql --cpus 4
    ==> virtualbox-iso: Starting the virtual machine...
        virtualbox-iso: The VM will be run headless, without a GUI. If you want to
        virtualbox-iso: view the screen of the VM, connect via VRDP without a password to
        virtualbox-iso: rdp://127.0.0.1:5953
    ==> virtualbox-iso: Error starting VM: VBoxManage error: VBoxManage.exe: error: The native API dll was not found (C:\windows\system32\WinHvPlatform.dll) (VERR_NEM_NOT_AVAILABLE).
    ==> virtualbox-iso: VBoxManage.exe: error: VT-x is not available (VERR_VMX_NO_VMX)
    ==> virtualbox-iso: VBoxManage.exe: error: Details: code E_FAIL (0x80004005), component ConsoleWrap, interface IConsole
    ==> virtualbox-iso: Deregistering and deleting VM...
    ==> virtualbox-iso: Deleting output directory...
    Build 'virtualbox-iso' errored: Error starting VM: VBoxManage error: VBoxManage.exe: error: The native API dll was not found (C:\windows\system32\WinHvPlatform.dll) (VERR_NEM_NOT_AVAILABLE).
    VBoxManage.exe: error: VT-x is not available (VERR_VMX_NO_VMX)
    VBoxManage.exe: error: Details: code E_FAIL (0x80004005), component ConsoleWrap, interface IConsole
    
  2. Support Staff 2 Posted by Ilya Finkelshte... on 22 Mar, 2019 12:25 AM

    Ilya Finkelshteyn's Avatar

    Hi Henry.

    Sorry for delay with reply. Right now we are testing new build worker image called Windows Server 2019 which runs on Azure Standard_D2s_v3 VMs with nested virtualization enabled.

    This image is not publicly available yet, we enable it for people as needed. It has been enabled for you. Please try and let us know if this works.

    Ilya.

  3. 3 Posted by henryfbp on 22 Mar, 2019 12:38 AM

    henryfbp's Avatar

    Hi Ilya,

    Thanks for the reply.

    As I unfortunately have moved to using self-hosted Jenkins with Hyper-V on Windows 10, I probably won't be using Appveyor.

    However, you are free to use my repo's code to test your virtualization.

  4. Support Staff 4 Posted by Ilya Finkelshte... on 22 Mar, 2019 12:44 AM

    Ilya Finkelshteyn's Avatar

    OK, sorry. Virtualization is tested: https://ci.appveyor.com/project/appveyor-tests/win2k19-azure.

    It would be cool if you delete AppVeyor projects you do not use so your commits do not trigger unneeded builds.

  5. 5 Posted by henryfbp on 22 Mar, 2019 12:46 AM

    henryfbp's Avatar

    Will delete my projects. Thanks again.

  6. Ilya Finkelshteyn closed this discussion on 22 Mar, 2019 12:48 AM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac