Ubuntu – Mount a VirtualBox drive image (vdi)


Is it possible to mount a VirtualBox drive image (.vdi) so the contents can be viewed in Nautilus etc.?

I have a windows 2000 .vdi which won't boot ("inaccessible boot device") after upgrading from VirtualBox 2.x to 3.1.6. I believe the IDE drive details have changed and that all I need to do is access the internal drive image and edit the Windows boot.ini to point to the new location.

Best Answer

You can convert into standard image and then mount it.

VBoxManage clonehd --format RAW ubuntu.vdi ubuntu.img


mount -t ext3 -o loop,rw ./ubuntu.img /mnt

You will need to KNOW the type of file system, ext3 in this case. After it is mounted, go in and edit away with the editor of your choice. Don't confuse files inside the /mnt location with the running host, or it will be bad.

To check details about your VDI file, run: VBoxManage showhdinfo ubuntu.vdi.

Source: [SOLVED] Open .vdi with archive manager? - ubuntuforums.org