virutal Box 解决导入.vdi文件时报“uuid is exists”错误 个人总结.

 

手工解决办法:

1.拷贝所有的*.vdi文件和*.vbox文件到自定义目录.

2.进入到virtual box 的安装目录.

运行:VBoxManage internalcommands sethduuid "F:\chroot\root.vid"

结果:UUID changed to: 1c2ec070-f76b-489e-b0b1-90f251911da9

 

C:\Program Files\Oracle\VirtualBox>VBoxManage internalcommands sethduuid "F:\chr
oot\root.vdi"
UUID changed to: 1c2ec070-f76b-489e-b0b1-90f251911da9

C:\Program Files\Oracle\VirtualBox>VBoxManage internalcommands sethduuid "F:\chr
oot\home.vdi"
UUID changed to: acccf709-f91b-4544-856a-c4cabb84952a

C:\Program Files\Oracle\VirtualBox>VBoxManage internalcommands sethduuid "F:\chr
oot\swap.vdi"
UUID changed to: e7f08078-1624-4d0b-a381-b2dc5f51b284

C:\Program Files\Oracle\VirtualBox>VBoxManage internalcommands sethduuid "F:\chr
oot\work.vdi"
UUID changed to: 12c7656c-496b-41b9-b2de-6ae0c5d25392

 

3.手动修改*.vbox文件:

<Machine uuid="{a2c8664f-54d7-4f02-ac7e-74d3884d3d61}" name="chroot" OSType="Debian" snapshotFolder="Snapshots" lastStateChange="2013-08-15T09:20:55Z">   //随便设一个uuid

.........................

     <HardDisks>
        <HardDisk uuid="{12c7656c-496b-41b9-b2de-6ae0c5d25392}" location="work.vdi" format="VDI" type="Normal"/>    //////对下面黄色的uuid
        <HardDisk uuid="{e7f08078-1624-4d0b-a381-b2dc5f51b284}" location="swap.vdi" format="VDI" type="Normal"/>
        <HardDisk uuid="{1c2ec070-f76b-489e-b0b1-90f251911da9}" location="root.vdi" format="VDI" type="Normal"/>
        <HardDisk uuid="{acccf709-f91b-4544-856a-c4cabb84952a}" location="home.vdi" format="VDI" type="Normal"/>
      </HardDisks>

.....................

        <AttachedDevice type="HardDisk" port="0" device="0">
          <Image uuid="{1c2ec070-f76b-489e-b0b1-90f251911da9}"/>
        </AttachedDevice>
        <AttachedDevice type="HardDisk" port="1" device="0">
          <Image uuid="{e7f08078-1624-4d0b-a381-b2dc5f51b284}"/>
        </AttachedDevice>
        <AttachedDevice type="HardDisk" port="2" device="0">
          <Image uuid="{acccf709-f91b-4544-856a-c4cabb84952a}"/>
        </AttachedDevice>
        <AttachedDevice type="HardDisk" port="3" device="0">
          <Image uuid="{12c7656c-496b-41b9-b2de-6ae0c5d25392}"/>
        </AttachedDevice>

 

总结:

第二步可以跳过,在每个uuid都加一就可以了.如12c7656c-496b-41b9-b2de-6ae0c5d25392 ,加一后:12c7656c-496b-41b9-b2de-6ae0c5d25393

你可能感兴趣的:(oracle,VirtualBox,vdi)