xengineer’s diary

結果、メモ的な内容になっています。

VirtulBox vdiファイルのコピー

先日、VirtualBoxの、インスタンスのストレージとして指定している、

HDD用vdiファイルをコピーして、コピー先のファイルを再度HDDに指定しようと

したところ、こんなエラーが。

f:id:xengineer:20150825103755p:plain

Cannot register the hard disk 'F:\virtualbox\wolverin00\wolverin00.vdi'
{xxxxxx-xxx-xxxx-xxxx-xxxxxx} because a hard disk hogehogheoghoeghoehgoehogheoghe
with UUID {yyyyyy-yyy-yyyy-yyyy-yyyyyy} already exists.

調べてみた。

www.bradleyschacht.com

どうやら、VirtualBoxでは、各仮想HDDに固有のUUIDを振って管理してるらしく、

重複しちゃあかん、ということみたい。

なので、コマンド打ってUUID変えましょう、と。

但し、これやる前に一旦、VirtualBoxを落とします。

インスタンスではなくて、VirtualBoxのアプリそのものを落としましょう。

で、下記コマンドを実行。

> cd <virtualboxのインストールパス>
> VBOXMANAGE.EXE internalcommands sethduuid <UUIDを変更したいvdiファイルのパス>

f:id:xengineer:20150825104451p:plain

そんで再起動すると、ちゃんと指定できるようになってる!はず。

そして無事インスタンスも起動できる!はず。

おしまい。