7

私はテストキッチンインスタンスを実行しましたが、すべて問題ありませんでしたが、最後にキッチンを破棄しようとしたとき:

roberto@pc:~$ kitchen destroy

Virtualbox でこのエラーが発生しました。

-----> Starting Kitchen (v1.1.1)
-----> Destroying <default-ubuntu-1204>...
       [default] Destroying VM and associated drives...
>>>>>> ------Exception-------
>>>>>> Class: Kitchen::ActionFailed
>>>>>> Message: Failed to complete #destroy action: [Expected process to exit with [0], but received '1'
---- Begin output of vagrant destroy -f ----
STDOUT: [default] Destroying VM and associated drives...
STDERR: There was an error while executing `VBoxManage`, a CLI used by Vagrant
for controlling VirtualBox. The command and stderr is shown below.

Command: ["unregistervm", "2507bc77-3734-429b-a573-d92fadb80e95", "--delete"]

Stderr: VBoxManage: error: Cannot unregister the machine 'default-ubuntu-1204_default_1391521776' while it is locked
VBoxManage: error: Details: code VBOX_E_INVALID_OBJECT_STATE (0x80bb0007), component Machine, interface IMachine, callee nsISupports
VBoxManage: error: Context: "Unregister(CleanupMode_DetachAllReturnHardDisksOnly, ComSafeArrayAsOutParam(aMedia))" at line 158 of file VBoxManageMisc.cpp
---- End output of vagrant destroy -f ----
Ran vagrant destroy -f returned 1]
>>>>>> ----------------------
>>>>>> Please see .kitchen/logs/kitchen.log for more details

Virtualbox を実行しましたが、インスタンスもロックされており、閉じるオプションが無効になっているため、インスタンスを削除できません。

この問題を抱えている他の人はいますか?

4

2 に答える 2

1

この問題の原因となることが 2 つあります。確認してください:

  1. VirtualBoxのインストール/更新後にコンピューターを再起動します
  2. ドライバーを使用する前に、手動で VirtualBox を少なくとも 1 回開いていることを確認してください。

マシンが VBox GUI の仮想マシンのリストに表示される場合は、コマンドを再試行してください。それらが VirtualBox GUI にリストされていない場合は、.kitchenディレクトリを削除して再試行してください。

于 2014-02-08T19:15:03.793 に答える