Closed DaStivi closed 8 years ago
WARNING -> this is ok because normally all machines should be running. It's to avoid "forgetting" systems and was required by a lot of users. Look into the command reference. You can map warning to ok.
UNKNOWN -> the status grey is deliverd from Vmware. So check your Vmware. Vcenter, datacenter - different names for the same thing. Unfortunately Vmware have changed the name. In 4.x it was the datacenter. Since 5.x is Vcenter. Same with fields returned from calls to the software. Older fields came with dc..., newer ones with vc... . So I decided to use Vcenter mainly. But I used -D from the commentline. This is for history. The plugin is derived from check_esx3.pl and the newer but not better check_vmware_api.pl. The goal was to replace as less options as possible.
./check_vmware_esx.pl -D vcenter -f /usr/lib/nagios/plugins/vcenter.auth -S runtime returns following state:
WARNING: 0/127 VMs suspended - 68/127 VMs powered off - 59/127 VMs powered on - 6/8 Hosts powered on - 2/8 Hosts powered off/standby/unknown - 3/3 Clusters green - 0/3 Clusters red - 0/3 Clusters yellow - 0/3 Clusters gray - 127 VMs checked for VMWare Tools state, 0 are not OK.
is OK State only if every vm is powered on?
the additional "-s status" switch returns: UNKNOWN: 0/2 Vcenters green - 0/2 Vcenters red - 0/2 Vcenters yellow - 2/2 Vcenters gray
at least it should not be named vcenters instead there should be datacenters i guess.... and the other thing is i don't know why they are marked as grey...
/usr/lib/nagios/plugins/check_vmware_esx.pl -D vcenter -f /usr/lib/nagios/plugins/vcenter.auth -S runtime -s all WARNING: 0/127 VMs suspended - 68/127 VMs powered off - 59/127 VMs powered on - 6/8 Hosts powered on - 2/8 Hosts powered off/standby/unknown - 3/3 Clusters green - 0/3 Clusters red - 0/3 Clusters yellow - 0/3 Clusters gray - 127 VMs checked for VMWare Tools state, 0 are not OK.