4

Windows 10 で Vagrant 1.8.1 を使用しています。ボックスを削除または破棄しようとすると、次の矛盾する結果が得られました。

baria@DESKTOP-057K4L5 /c/repos/hub/vtc/linphone-windows-dependencies
$ vagrant box list
hashicorp/precise64  (virtualbox, 1.1.0)
windows_2012_r2_core (virtualbox, 0)

baria@DESKTOP-057K4L5 /c/repos/hub/vtc/linphone-windows-dependencies
$ vagrant box remove windows_2012_r2_core
Box 'windows_2012_r2_core' (v0) with provider 'virtualbox' appears
to still be in use by at least one Vagrant environment. Removing
the box could corrupt the environment. We recommend destroying
these environments first:

vagrant-windows-2012-r2-core (ID: 00d3488f41fa40998bfe16ada2ebfd31)

Are you sure you want to remove this box? [y/N] N

baria@DESKTOP-057K4L5 /c/repos/hub/vtc/linphone-windows-dependencies
$ vagrant destroy windows_2012_r2_core
The machine with the name 'windows_2012_r2_core' was not found configured for
this Vagrant environment.

「Vagrant 環境」とは何かについての説明をグーグルで検索しましたが、何も見つかりませんでした。だから、「環境を破壊する」方法がわかりません。

それでも、およびコマンドがボックスの存在を認識していることを考えると、コマンドがボックスdestroyの存在を認識することを期待します。windows_2012_r2_corelistremove

ここで何が起こっているのですか?警告やエラーなしで、このボックスをきれいに取り除くにはどうすればよいですか?

4

2 に答える 2

5

参照vagrant destroy 00d3488f41fa40998bfe16ada2ebfd31されている VM を破棄すると、このボックスを使用している VM が破棄され、ボックスを削除できるようになります。

vagrant global-status@Brandon Davis が言及しているように、作成された vagrant VM (vagrant 1.6+ から) のリストを表示するために実行でき、どの VM が 00d3488f41fa40998bfe16ada2ebfd31 であるかを確認できます。

于 2016-02-25T20:00:45.887 に答える
2

リストから無効なエントリを削除する必要があります。

vagrant global-status --prune

コマンドの詳細については、こちらを参照してください。

于 2016-02-25T01:11:34.447 に答える