Tell me more ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Is there any tool to mount a .vdi file (and/or examine its partitions) in Unix/Linux?

share|improve this question
Not a programming question, I suggest asking on ServerFault or SuperUser – Dan Grossman Dec 9 '10 at 1:25

migrated from stackoverflow.com Dec 9 '10 at 1:46

4 Answers

I have successfully used qemu-nbd (which comes with the qemu package) to access VirtualBox .vdi disks.

First you make sure that the nbd kernel module is loaded with the max_part option set to a number high enough to accommodate all the partitions in your .vdi image:

# rmmod nbd
# modprobe nbd max_part=16

Then you use qemu-nbd to attach the image:

# qemu-nbd -c /dev/nbd0 test.vdi

You will get a /dev/nbd0 block device, along with several /dev/nbd0p* partition device nodes. You use them as any other disk. Once you are done, you unmount everything, and disconnect the device:

# qemu-nbd -d /dev/nbd0
share|improve this answer

You can try for CloneVDI tool for your .VDI files, refer to below URL for more details.

http://forums.virtualbox.org/viewtopic.php?f=6&t=22422

share|improve this answer

it looks like vdfuse is the tool you are looking for. It is in the Ubuntu repositories. If you want to compile yourself (2010 source) you can do that too.

share|improve this answer

Short of using another emulator, you can use a loopback device to mount it. Instructions are available via Google, although one nice one I found is here. This will allow you to mount it as a loopback device.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.