HiperLogic

Virtualization, High Performance Computing, Healthcare IT, Enterprise Computing

May 2010

You are currently browsing the monthly archive for May 2010.

A customer was trying to back up a VM with a 20GB OS vmdk and a 1TB vmdk on two different VMFS datastores over iSCSI with a 1MB block size and 8MB data size respectively, and received the error below when trying to snapshot the VM:

File <unspecified filename> is larger than the maximum size supported by datastore <unspecified datastore>

To check the block size of a VMFS datastore go to the VI Client, with vSphere:
1.Select an ESX host that contains the datastore.
2.Click the Configuration tab.
3.Click Storage.
4.Click on the datastore.
5.The block size is identified in the Details window under the Formatting subheading

The basic block size to virtual disk size is below ( in vSphere, which is DIFFERENT than ESX 3.X )

Block Size VMDK Size
1MB 256GB-512 Bytes
2MB 512GB-512 Bytes
4MB 1TB-512 Bytes
8MB 2TB-512 Bytes


To fix the issue, the OS VMDK residing on the 1MB block size VMFS datastore must be migrated to a datastore with a 8MB block size (It is a best practice is to have all VMFS datastores with the same block size to avoid such issues.)

blocksize

Note this issue does not apply to NFS datastores.

Veeam Backup has an option to write the last backup time to a vCenter attribute. This is a nice feature that enables anyone using the VMware VIC client to see the last time a VM was backed up.

This feature makes it easy to write a script to ensure all VMs are backed up by querying this attribute with PowerCLI. Veeam emails you the status of all VMs it knows about ( that are in backup jobs ), but it is possible someone could add a VM that does not get added to your existing Veeam backup jobs.

The script to check for this issue is below.

1. Modify the script below to have the name of your vCenter server in $vCenterServer
2. Configure your Veeam Backup job to write to the “Backup” attribute on completion ( The default is Notes attribute, which is often used by Admins for other items ).
3. This script assumes that every VM is backed up at least once a day.
4. Run this script at the PowerCLI command prompt. See this 5 minute guide to PowerCLI to get started.

function get-backedup ($vm)
{
# This should be one line
$val = $vm.CustomFields |where {$_.key -eq "Backup" } | select -Property Value
$today = Get-Date -Format "M/d/yyyy"
$backupDate = $val.Value

return ( $backupDate -like "*$today*" )

}

Connect-VIServer $vCenterServer 

$vms = get-vm
foreach ($vm in $vms)
{
  if (get-backedup($vm)) {
      write-host -foregroundcolor green "$vm is backed up"
  } else {
      write-host -foregroundcolor red "$vm is NOT backed up"
  }
}

Tags: ,

Installing VMware Tools in a Windows or Linux VM increases the I/O timeout for all disks to help the guest OS survive a short SAN/NAS storage outage.

If you wish to increase this value from the VMware default ( or if you don’t install VMware tools for some reason), there are couple ways to automate this. Jason McCarty last week posted a nice PowerCLI script to automatically set Windows Guest timeout registry setting to the NetApp recommended value of 190 seconds: http://www.jasemccarty.com/blog/?p=691.

If you are running RHEL5 with vSphere U1 VMware tools installed, the default is set to 180 seconds in /etc/udev/rules.d/99-vmware-scsi-udev.rules. You can increase this if you want by editing this file, or manually set /sys/block/sda/device/timeout in /etc/rc.local to avoid a VMware tools upgrade from changing your settings.

© 2006-2010 HiperLogic, LLC.  |  Serving the Ann Arbor, Southeast Michigan, and Ohio region  |  (888)-268-3930  |