25 August 2011 / #Powercli #Vsphere

vCheck v5++


EDIT 29/09/2011 : Version 5.5.1 - Patching some minor bugs (thanks to MacBookeur for testing)

Today comes out our lovely hypervisor v5. Whith this new version comes great new features :p We will not speak of that, it is not the goal of this post, but rather to update the reporting-in-a-script aka vCheck.

For those who don’t know, vCheck is a script made by Alan Renouf (available here) and modified by our coworker This helps to quickly make a report of what happened to your VMware platform and receive this lovely report by mail.

Since the last version, we changed this script by adding new features, optimizing the execution time (very useful for large infrastracture :p) and correcting small bugs.

Here is what you can find new in this version (non-exhaustive list, see the header of the script for complete information) :

  • ESX5 update (replacing obsolete property/method)
  • Adding Storage DRS Summary Info (Storage DRS Migrations count) and Maintenance Mode check
  • Tuning : Support of non HA Cluster for Capacity Planner
  • Checking for Thick Format disk on templates
  • Adding user exception for snapshot created/removed
  • Added TimeToBuild details for all modules (useful for large environnement informations)
  • Adding empty custom fields check
  • Optimization of objects call (based on Get-View collections at the begining of the script) > less execution time
  • Using CSS3 for coloring even lines : tr:nth-child(even), enhance view on huge table
  • Putting report on XHTML 1.0 Strict W3C compliant
  • Adding a debug mode (all tests, headers and TTB are shown)
  • Adding check made by

In order to test the script or wanted to use debug mode, we recommand you to source the script with the following command :

. ./vCheck-v551.ps1

It allows to keep variable content after the end of the script, very useful for debugging.


For scheduled tasks, here’s a export XML file in order to launch vCheck script on Windows 2008 (you’ll just need to change  path/user/password/frequency and import it) :

<?xml version="1.0" encoding="UTF-16"?>
<Task version="1.1" xmlns="">
    <Principal id="Author">
  <Actions Context="Author">
      <Arguments>-command "c:\Scripts\vCheck\vCheck-v551.ps1 -VISRV vcenter-serveur -sendmail $true -htmlsave $true"</Arguments>

We’d like to thanks a lot Alan and for this amazing tool, it’s really awesome, usefull daily, and even better than :

Macgyver Tool

And of course, we’ll update the script in the near future with new feature/check ^^

> Frederic MARTIN