Everyday Virtualization

Blog archive

P2V Tip: VMDK Pre-Build

I am always looking for ways to make a physical-to-virtual conversion go better. While I love the venerable VMware vCenter Converter for most workloads, I still find situations where I can't allocate the time to do a conversion this way.

In addressing some unstructured data systems, a new approach revealed itself: the VMDK pre-build. When I say unstructured data, I am simply referring to situations such as a very large number of very small files. While I'd rather deal with a database putting this content into a blob format, I'm often dealt the unstructured data card.

So, what do I mean by a VMDK pre-build? Basically, I deploy a generic virtual machine within vSphere and attach an additional VMDK disk. From that generic virtual machine, I launch a series of pre-load operations onto the additional VMDK disk. The pre-load copies the unstructured data ahead of time to a VMDK disk. This can be done via a number of tools, including the quick and easy
Robocopy scripting options, RichCopy graphical interface and more advanced tools that you can buy from companies like Acronis or DoubleTake. By using one of these tools to pre-populate the VMDK file, you can save a bunch of time on the actual conversion.

Taking the VMDK pre-build route, of course, assumes that the Windows Server has a C:\ drive that is separate of the collection of unstructured data. At the time of the conversion, using VMware vCenter Converter for the C:\ drive will take a very short amount of time. After the conversion, you simply remove the VMDK from the generic virtual machine, and attach it to the newly converted virtual machine. There, you've saved a bunch of time.

The tools above can be tweaked to add some critical options on the pre-load of the VMDK disk. This can include copying over Windows NTFS permissions, as well as re-running the task to catch any newly added data. Robocopy, for example, will proceed much quicker once the first pass is completed and pick up only the newly added data.

The tip I provide here isn't the solution for a SQL Server or Exchange Server, of course, but the use cases can apply to anything that has a large amount of data that may take a long time to convert via the traditional methods.

Have you ever used this trick in performing your P2V conversions? If so, share your experience here.

Posted by Rick Vanover on 05/25/2010 at 11:32 AM


Reader Comments:

Wed, May 26, 2010 Rick Vanover http://rickatron.us

MOE: This trick is only best suited for "unstructured data".

I'd happily use VMware Converter when the file sizes are usually in the MB. If you are dealing with 250 GB of files at 5K, it can take forever.

Wed, May 26, 2010 Tom Knoxville, TN

I have used robocopy like this to complete P2V's. Works great for servers with large disks that need to be virtualized. #

Tue, May 25, 2010 Jonathan Reinigner Springfield, IL

From some P2P (not P2V) conversations I have done, you want to be on the lookout for file paths that become greater than 255 characters long when using Richcopy or Robocopy. This becomes a problem for both richcopy and robocopy since when the source and destination paths now includes the \\ and the admin share drive letter and one more backslash. This can cause files to get lost in the data transfer as outlined above by Rick Vanover. When working w/ user data, more often that not files that are automatically created in a users folder redirected H:\ drives will exceed the total file path length. Or at times users will bury files in there own H:\ drive too deep. The file name is valid in there own reference (ie they see H:\-long file name-. But when using Richcopy or Robocopy the job must address it with by additionally using the server name and admin share letter which might make the path too long (\\server\d$\home\userid\-longfilename-.doc).

Richcopy while faster can also fragment the heck out of the destination drive. I have seen it where files copied from a 20G drive to a virtual 20G drive wont fit due to excessive fragmentation which cause the copy job to fail. Our Operations guys now use a Brightstore copy job which gets around the file length problem and the fragmentation problem of Richcopy.

Just be on the lookout if you are going to try Richcopy or Robocopy in methods as outlined in the above article. I am sure a Google search will detail these limitations as well.

Tue, May 25, 2010 Moe

Rick, interested in learning a little bit more about your process. We use the vCenter Converter to complete the P2V for server containing 200-250GB of data. It does take quite a bit of time. I kinda follow your process but get a little lost when you start discussing the "pre-load operations"...do you have this entire process outlined in a little more detail that you would be willing to share?

Add Your Comment:

Your Name:(optional)
Your Email:(optional)
Your Location:(optional)
Comment:
Please type the letters/numbers you see above