I’ve recently been converting some VMWare Fusion VM’s to VirtualBox and part of that process I had to re-remember how to do after having done it before. This serves as my memory, and some documentation, on how this is done.
In the most recent conversion I had the need to convert from a snapshot, luckily I only had one snapshot, to a regular disk and I no longer have VMWare Fusion installed. You can download vmware-vdiskmanager and use it to convert a snapshot into a new vmdk disk that can be used by VirtualBox. Example usage:
$ ./vmware-vdiskmanager -r /path/to/vm/disk01-000001.vmdk -t 0 /path/to/vm/newdisk.vmdk
Continuing on you need to reconfigure the VM, run as root, it’s easier.
$ /usr/bin/vmware-uninstall-tools.pl
$ rm -rf /etc/udev/rules.d/70-persistent-net.rules
$ apt-get update
$ apt-get upgrade
$ apt-get install dkms
$ reboot
Mount the VirtualBox Guest additions ISO from VirtualBox
$ mkdir /mnt/cdrom
$ mount /dev/scd0 /mnt/cdrom
$ cd /mnt/cdrom
$ sh VBoxLinuxAdditions.run
$ reboot
If you are using the Shared Folders feature of VirtualBox I’d recommend editing /etc/group. You can add other users as needed, I normally add devuser at the same time as that is the user I use on my dev VM’s.
vboxsf:999:www-data,devuser
Any linking you did to /mnt/hgfs/SHAREDFOLDER will now need to be changed to linking to /media/sf_SHAREDFOLDER, provided you told VirtualBox to auto mount the shared folder.
Wow, this saved me a couple times, now.
And also, dont forget to reboot the vm!