2016-08-23 91 views
2

我試圖讓一個OSX(理想情況下,埃爾卡皮坦)框設置在流浪漢下。我的主機操作系統是El Capitan 10.11.6(15G31)。如何在流浪漢下運行OSX El Capitan Box?

這裏是我到目前爲止

vagrant init 
vagrant box add jhcook/osx-elcapitan-10.11 
# edit vagrant init such that config.vm.box = "jhcook/osx-elcapitan-10.11" 
vagrant up 

不過,我得到以下錯誤的嘗試:

Bringing machine 'default' up with 'virtualbox' provider... 
==> default: Importing base box 'jhcook/osx-elcapitan-10.11'... 
==> default: Matching MAC address for NAT networking... 
==> default: Checking if box 'jhcook/osx-elcapitan-10.11' is up to date... 
==> default: Setting the name of the VM: ratatouille_default_1471905801413_58611 
==> 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... 
There was an error while executing `VBoxManage`, a CLI used by Vagrant 
for controlling VirtualBox. The command and stderr is shown below. 

Command: ["startvm", "e1aafdeb-650b-4b94-89cf-4ef39e22e7f6", "--type", "headless"] 

Stderr: VBoxManage: error: Implementation of the USB 2.0 controller not found! 
VBoxManage: error: Because the USB 2.0 controller state is part of the saved VM state, the VM cannot be started. To fix this problem, either install the 'Oracle VM VirtualBox Extension Pack' or disable USB 2.0 support in the VM settings. 
VBoxManage: error: Note! This error could also mean that an incompatible version of the 'Oracle VM VirtualBox Extension Pack' is installed (VERR_NOT_FOUND) 
VBoxManage: error: Details: code NS_ERROR_FAILURE (0x80004005), component ConsoleWrap, interface IConsole 

我在做什麼錯?

如何禁用USB 2.0支持?

編輯:那些投票結束,你能告訴我什麼問題是?我很樂意糾正它。

+0

有你累了修復錯誤? 「由於USB 2.0控制器狀態是保存的虛擬機狀態的一部分,所以虛擬機無法啓動。要解決此問題,請安裝'Oracle VM VirtualBox擴展包'或禁用USB設備中的USB 2.0支持。 –

回答

3

好的,它非常簡單。我在這方面與Vagrant的經驗不足有關。

添加以下行Vagrant.configure(2) do |config|塊已經解決了這個問題(感謝@TomMillard):

# disable USB 2.0 
    config.vm.provider "virtualbox" do |vb| 
     vb.customize ["modifyvm", :id, "--usb", "off"] 
     vb.customize ["modifyvm", :id, "--usbehci", "off"] 
    end