Friday, July 13, 2012

Daily Health Reports for vCenter by Alan (http://www.virtu-al.net)

Have you ever thought.. get "Granular Report" of your VC - Full view of VC on HTML report!!
You should visit below..


http://www.virtu-al.net/vcheck-pluginsheaders/vcheck/



Report contains below - Damn easy via Power CLI..
  • General Details
    • Number of Hosts
    • Number of VMs
    • Number of Templates
    • Number of Clusters
    • Number of Datastores
    • Number of Active VMs
    • Number of Inactive VMs
    • Number of DRS Migrations for the last days
  • Snapshots over x Days old
  • Datastores with less than x% free space
  • VMs created over the last x days
  • VMs removed over the last x days
  • VMs with No Tools
  • VMs with CD-Roms connected
  • VMs with Floppy Drives Connected
  • VMs with CPU ready over x%
  • VMs with over x amount of vCPUs
  • List of DRS Migrations
  • Hosts in Maintenance Mode
  • Hosts in disconnected state
  • NTP Server check for a given NTP Name
  • NTP Service check
  • vmkernel warning messages ov the last x days
  • VC Error Events over the last x days
  • VC Windows Event Log Errors for the last x days with VMware in the details
  • VC VMware Service details
  • VMs stored on datastores attached to only one host
  • VM active alerts
  • Cluster Active Alerts
  • If HA Cluster is set to use host datastore for swapfile, check the host has a swapfile location set
  • Host active Alerts
  • Dead SCSI Luns
  • VMs with over x amount of vCPUs
  • vSphere check: Slot Sizes
  • vSphere check: Outdated VM Hardware (Less than V7)
  • VMs in Inconsistent folders (the name of the folder is not the same as the name)
  • VMs with high CPU usage
  • Guest disk size check
  • Host over committing memory check
  • VM Swap and Ballooning
  • ESXi hosts without Lockdown enabled
  • ESXi hosts with unsupported mode enabled
  • General Capacity information based on CPU/MEM usage of the VMs
  • vSwitch free ports
  • Disk over commit check
  • Host configuration issues
  • VCB Garbage (left snapshots)
  • HA VM restarts and resets
  • Inaccessible VMs

Virtual CD - becomes "Show Stopper" for Manual / DRS vMotion - How to solve


Virtual CD - becomes "Show Stopper" for Manual / DRS vMotion - How to solve

1) Tool Based Disconnect (As per docs - host wise)
2) Power CLI based Disconnect (By ESX, Cluster, Datacenter) - Single Shot

Method1 - Tool Based
There is a tool by "Eric Sloof" - This Tool Scans all Virtual Machines and shows if they have a CD connected to it. After scanning the VM’s you can disconnect all the CD’s with a click of  a button.

Method2 - Script Based -I like this way - Power of Reach to ESX / Cluster / Data Center

Execute Script on one ESX Host & disconnect Virtual CD for All VM's on ESX
(Get-VM -Location ( Get-VMHost "ESX host name HERE")) | `
ForEach ( $_ ) { Get-CDDrive $_ | `
Where { $_.IsoPath.Length -gt 0 -OR $_.HostDevice.Length -gt 0 } | `
Set-CDDrive -NoMedia -Confirm:$False }

Execute script on Whole cluster:
(Get-VM -Location ( Get-Cluster "Cluster Name HERE")) | `
ForEach ( $_ ) { Get-CDDrive $_ | `
Where { $_.IsoPath.Length -gt 0 -OR $_.HostDevice.Length -gt 0 } | `
Set-CDDrive -NoMedia -Confirm:$False }

Why not by Datacenter:
(Get-VM -Location ( Get-Datacenter "Datacenter Name HERE")) | `
ForEach ( $_ ) { Get-CDDrive $_ | `
Where { $_.IsoPath.Length -gt 0 -OR $_.HostDevice.Length -gt 0 } | `
Set-CDDrive -NoMedia -Confirm:$False }