computing
  • 7

Solved How To Copy Files From a Guest OS To Host OS?

  • 7

yeah right, vm. virtualbox.. just for fun I didn’t download the guest additions, so no shared folders. is there any alternative way to copy files from guest os to host os? my host PC s peppermint 5 and guest is winxp.

Share

1 Answer

  1. Here’s one way to transfer files without guest additions. It works with Virtualbox, and QEMU images. I learned this by searching on the internet.
    First, make sure the guest VM that you want to copy files from isn’t running.
    You will also have to have a driver for NTFS filesystem in your case.
    If you have QEMU-utils installed, you can use:

    sudo modprobe nbd max_part=16 #this loads network block device driver into kernel

    then…

    sudo qemu-nbd -c /dev/nbd0 <path to your VBox hdimage.vdi> #binds your hdimage to network block device, which can then be mounted as a normal filesystem.

    and lastly…

    sudo mount /dev/nbd0p1 /mnt #or wherever you’d like to mount it.

    When you’re done transferring files you’ll need to unmount the filesystem and…

    sudo qemu-nbd -d /dev/nbd0 #unbind hdimage from network block device.

    That’s it.
    I’ve used it several times, and it works very well.

    message edited by pbznmg18

    • 0