Having first tested VM portability from VMware Workstation (on Windows) to VMware Fusion (on Mac OS X), then portability from ESX Server to VMware Fusion, the next logical step was VMware Fusion to ESX Server. I ran into one surprise but, as I expected, the process worked without any major hiccups.
The first step was to get the virtual disk files from my MacBook Pro over to ESX Server. Last time, when I ran this process in reverse, I used the open source SFTP client Cyberduck to copy the VMDK files down from ESX Server to my laptop. That worked well, but took a bit longer than I would have liked. This time, I dropped into the OS X Terminal and used command-line SCP. The command looked something like this (typed from the same directory where the VMDK file resided):
scp ontap.vmdk esx01.example.net:/vmimages/uploads
(Full disclosure: I actually used a wildcard glob to pick up all the VMDK files, but you get the general idea.) This copied the files much more quickly than with Cyberduck. I believe this is less a comparison of Cyberduck vs. command-line SCP and more of a comparison between the SFTP and SCP protocols themselves. I intend to try the open source graphical SCP client Fugu to see if performance there supports that conclusion.
In any case, once the VMDK files were up on the host, it’s vmkfstools once again to the rescue (again, typed from the directory where the original VMDK files resided):
vmkfstools -i ontap.vmdk /vmfs/volumes/isanvol0/ontap/ontap.vmdk
Now that the VMDK files were on the ESX Server and imported into a VMFS datastore in the right format, I had only to create a virtual machine with the right configuration and attach it to the virtual disk. I suppose I could have copied the VMX file over as well and then used vmware-cmd to register the virtual machine….maybe next time.
Here’s where it got weird (this is the one surprise I encountered). I created a new virtual machine in VirtualCenter but when I went to attach it to an existing virtual disk, none of the virtual disks would show up. I simply could not see them in the VI Client. And not just the VMDK files I’d just imported, but any of the VMDK files. I double-checked permissions—no problems there. I re-imported the files with vmkfstools—no difference. Finally, I created a blank disk for the new virtual machine, then edited the VMX file to point to the VMDK file I’d imported. Then I powered on the VM.
Other than some USB and networking-related errors on the first boot (which were easily corrected by editing the VMX file), the VM worked exactly as expected. Other than the weirdness with locating the VMDK files to attach to the VM, the whole process took only 10 or 15 minutes, and most of that was copying data up to the ESX Server.
As I pointed out in my earlier articles on VM portability, this is proof-positive that VMware’s virtualization layer provides an excellent vehicle for moving workloads across hardware as well as operating systems. Although I haven’t included VMware Workstation on Linux in these tests, I fully expect it would behave in the same fashion as VMware Workstation for Windows. VMware Server should also be very much like, if not identical, to VMware Workstation as well. This gives us a solution that lets us scale workloads from workstation-class hardware, to server-class hardware (but still hosted on a host OS), then to enterprise-class virtual infrastructure (on the bare metal). Good stuff!
Tags: ESX, Interoperability, Macintosh, Virtualization, VMware


3 comments
Comments feed for this article
Trackback link
http://blog.scottlowe.org/2006/12/12/vm-portability-round-3/trackback/
Tuesday, December 12, 2006 at 2:41 pm
John Troyer
Have you tried it with VMware Converter? I haven’t myself, but I gather it can take care of the fiddly bits for you.
Tuesday, December 12, 2006 at 4:57 pm
slowe
John,
No, I haven’t tried it yet, either. Since VMware Converter runs only on Windows, I’d have to run VMware Converter inside a VM. I’m sure it would work, but it would be a bit of a hurdle to get access to the right files on the host inside the VM. I’ll have to give it a try as soon as I get a chance.
I really think, though, that judicious use of platform-specific options (like USB 2.0, which is only supported on Fusion and the upcoming Workstation 6.0) will help with portability across platforms. The biggest problem I had was the inability–for whatever reason–to browse existing VMDK files and attach them to the new virtual machine. I still haven’t figured out why that was happening.
BTW, I saw the link up on Planet V12n for my site…thanks! It’s an honor to be included.
Scott
Tuesday, December 19, 2006 at 2:44 am
John Troyer
Yeah, USB 2.0 support will cause a lot of headaches to go away, especially in P2V. The biggest stupid config problem right now on is still IDE vs SCSI drives. It’s easy to redefine one as the other, but still is a big gotcha for portability right now.
Oh, and welcome to Planet V12n — you’re writing good stuff; you’re entitled. Good original content is always appreciated!