Oh Snap! Watch your block size!

23 02 2010

             So, here is the scenario.  You have a VM with a regular, lets say 40GB OS drive, and a 300 GB Data drive.  Now you want to backup the vm using something like vranger or veeam.  As part of the backup process, the VM is snapshotted (is that a word?).  Only problem is, you get this lovely error….


          Uh oh!  But my OS and Data drive are on separate volumes!  There is plenty of room on both!  What gives?  It all boils down to where your working directory is, and the block size of the volume that it resides on.  As you may know, when you are creating and formatting a volume for use in vsphere, you are asked what block size you would like to use.  By default this is set to 1MB block sizes.  The block size directly relates to how large of a file that can be created on the datastore. Let’s look at a table of the maximums as it relates to block size.

Block Size                            Maximum File Size

1MB 256 GB
2 MB 512 GB
4 MB 1024 GB
8 MB 2048 GB

                As you can see, if you go with the default 1MB block size, you can only have a file of 256GB in size.  One more piece of the puzzle reveals our underlying issue….the working directory.


                In vsphere, when a snapshot is created, there are some checks that are done to make sure that files created can fit into the datastore.  BUT this check is done against the datastore that contains the working directory for your VM.  In our example, the OS drive.  If our OS datastore only has a 1MB block size, it thinks that your 300GB snapshot of your data drive wont fit!  It does not base it’s estimation on if it will fit on the datastore where the 300GB vmdk resides, but instead on where the working directory resides……the 1MB block size datastore!  We cant fit a 300GB file on a 1MB block size datastore, so the snapshot fails!

                 Ok great.  It failed.  Now what?  We need to storage vmotion the OS drive and configuration files to a datastore with an 8MB block size.  This is to accommodate a secondary drive all the way up to 2TB, while simultaneously changing the working directory.  Right click the offending vm, choose Migrate, then Change Datastore, then click the advanced button and select a datastore for the config file and hard disk 1 that has a 8MB block size.


Once the storage vmotion is complete, you can now snaphot your vm and get it backed up!


More info:




How to: Get a VSphere Client working on a Windows 7 RC or RTM machine

16 09 2009

Update:  If you are running the Update 1 or later on your hosts, the vSphere client it now works with Windows 7.

I have been struggling with this ever since going over to the Windows 7 RTM.  Over at the vmware community forums, GlenR has posted a zip file that when extracted to the right place, lets you run the vsphere client on Windows 7!  Thanks GlenR! I am going to expand on his work with a step-by-step…

1.  Go here to get the zip file…


His post is about halfway down.  Download that zip file to your computer.



2.  Next step is to download and install the vsphere client from your vcenter server if you havent already.  Just go to the vcenter IP or hostname in your browser and click Download vSphere client.

3.  Once you have the client installed, extract the zip file to c:\Program Files (x86)\VMware\Infrastructure\.  Make sure to overwrite the files with what is in the zip file.

4. Now browse to c:\Program Files (x86)\VMware\Infrastructure\Virtual Infrastructure Client\Launcher.  You will see a start_viclient batch file in there.  That’s what you need to run to launch the client.


5.  Now, to make it a little more elegant, edit the vsphere client shortcut on your desktop.  Delete the vpxclient reference, and instead reference the start_viclient batch file instead.  In the latest version of GlenR’s zip file, you can also use the shortcut’s he has included if you like.  You are good to go!


VMWorld 2009 Lab notes:VSphere Advanced Topics

31 08 2009

New features, best of, advanced features…
1. You can link virtual centers as one.
2. Licensing is now via just a key.
3. Look and feel is changed. It is much more icon driven.
4. Host profiles have been added. You can take a baseline of a host, and then deploy the profile.
5. You can now create a distributed virtual switch. Network state and vlans stay with the vm as it is vmotioned. You can only get this with enterprise plus.

Help I can’t vmotion with vsphere!

5 06 2009

Are you having trouble using vmotion after you upgraded to vSphere? There seems to be an issue where some improper cpu-id masks are applied as part of the hardware upgrade procedure. When you go to migrate a machine, you will get a cpu mismatch error. VMWare has addressed the problem with this KB article….


You basically shutdown the vm, go to edit settings, go to options, then down to CPU-ID and click advanced. Then click Reset All to Defaults. Click ok, then boot the vm back up. That should let you vmotion the vm around again. You will have to do this for all you vms that are having an issue.

Notes from the vSphere upgrade

1 06 2009

Here are a few tips from my experience with doing an in-place upgrade to vSphere….

1. If you are running vCenter and Update Manager in vms, make sure to move those vms off the host MANUALLY before trying to upgrade the host to vSphere.

2. When upgrading tools and hardware, and you have vCenter and update manager in vms, upgrade vCenter and Update Manager FIRST. This will make update manager and vcenter ready to use baselines and remediation to upgrade tools and hardware on other guests.

3. Use the vi client and login to the actual host that is running the vCenter and update manager vms, when upgrading tools and hardware on vCenter and update manager. Once they are upgraded, you can then log back in to your vCenter server like normal to do the other upgrades.

4. It may take an extra reboot of your vCenter of Update Manager vms for them to reliably see eachother after a tools/hardware upgrade.

VSphere Vmware Tools on Server 2008 Workaround

1 06 2009

I have been working through our upgrade to vSphere, and so far the only thing that has really been a big issue is the UNINSTALL of vmware tools on our existing Windows Server 2008 vms. If you run the upgrade for vmware tools, it will of course attempt to uninstall the previous version. Problem is, it doesnt work. It basically half uninstalls the previous version, leaving you with registry entries and so forth that make the new install of tools FAIL. If you find yourself in this predicament, try these steps.

1. Keep in mind, this is AFTER the uninstall of vmware tools has failed when upgrading on a Server 2008 vm.

2. Go to the vm in question, and open the console. Go to the VM menu, then guest, then install/upgrade vmware tools. This will mount the iso for installation. Exit out of the autorun box that comes up.

3. Get to a command prompt, and switch over to your cd drive that has the tools iso mounted. Now run this command……..”setup /c” This command will force remove all the registry entries and so forth and completely remove the old version of vmware tools.

4. Now, you may be tempted to just run setup from the command prompt at this point. DONT DO IT. Instead, go back out to the desktop and autorun the cd, and run setup from there. This will make sure that the install iso is available upon the reboot of your vm to finish the install process. Again, run it from autorun, NOT from the command prompt.

5. Once the vm reboots, it should finish up the tools upgrade, and you will be ready to upgrade the vm hardware to version 7.

6. One thing about upgrading the hardware on a server 2008 vm….When the vm comes back up after hardware upgrade, it will seem like the server is ready to go. In Server 2003, after hardware upgrade, you get the standard “Windows has installed new devices, you need to reboot” prompt. You dont get that prompt with Server 2008. REBOOT AFTER THE HARDWARE UPGRADE ANYWAY. There are a bunch of services that dont start properly on the first boot after hardware upgrade. A reboot will get these services going again.

vSphere upgrade part 4, step-by-step

26 05 2009

The following notes are from a series of vSphere update videos made available by vmware. These notes should help you upgrade your infrastructure step-by-step.


Licensing: Implementing vSphere licensing

1. Login to your vi client, now go to licensing on the home page.

2. Click Manage vSphere Licenses on the top right.

3. Now copy and paste your license keys out of your license portal into the window that comes up, and then select add license keys. You should now see the details of each key at the bottom.

4. After clicking next, its time to assign the keys to hosts. Select your hosts to assign then select a license. Review your selections, and hit finish.

5. You can see the licensing for each host, by selecting a host, and going to the cofiguration tab. You can also edit the settings from this view.

6. That’s it! Your infrastructure should now be fully operational on the new licenses! Congratulations! If you have completed all four parts, it’s time to kick back for a little bit and sip on a cold one…..:)