box_293, Plugin unable to retrieve datastores information

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
jyoti22
Posts: 254
Joined: Mon Mar 23, 2015 4:50 am

box_293, Plugin unable to retrieve datastores information

Post by jyoti22 »

Hi box_293,

box293_check_vmware.pl is unable to retrieve any datastore details from vCenter. I am getting the message "No datastores found", where as the hosts details can be retrieved. But not datastores

I logged into vcenter home->inventory->datastores and clusters, and I can see many datastores present

Thanks,
Jyoti
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: box_293, Plugin unable to retrieve datastores informatio

Post by rkennedy »

Please show us the command definitions, and service definitions that are related to this, so we can see how you're using the plugin.
Former Nagios Employee
jyoti22
Posts: 254
Joined: Mon Mar 23, 2015 4:50 am

Re: box_293, Plugin unable to retrieve datastores informatio

Post by jyoti22 »

Hi,
Please find screenshots of service definition and command definition of datastores

Thanks,
Jyoti
You do not have the required permissions to view the files attached to this post.
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: box_293, Plugin unable to retrieve datastores informatio

Post by tgriep »

It looks like it is a permission issue for the vi-admin account.
I found this explanation from the manual for the plugin.
Plugin fails to find objects such as Datastores
It has been observed that in some instances the plugin cannot locate datastores. For example:
Command:
• ./box293_check_vmware.pl --server vcenter.box293.local --check Datastore_Usage --name VOL_01
Output:
• UNKNOWN: Datastore 'VOL_01' not found
The problem is with the permissions that have been applied in the vSphere Client. For some reason assigning
the permissions at the top level of “Inventory > Hosts and Clusters” is not enough. You need to also assign the
permissions at the top level of “Inventory > Datastores and Datastore Clusters”.
Be sure to check out our Knowledgebase for helpful articles and solutions!
jyoti22
Posts: 254
Joined: Mon Mar 23, 2015 4:50 am

Re: box_293, Plugin unable to retrieve datastores informatio

Post by jyoti22 »

The permissions are in place.
We checked it.
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: box_293, Plugin unable to retrieve datastores informatio

Post by rkennedy »

Could you show us how they're set? It sounds like everything for this part is working properly otherwise.

The only part that would stop VMWare from polling the information is if the information is not presented on a query.
Former Nagios Employee
jyoti22
Posts: 254
Joined: Mon Mar 23, 2015 4:50 am

Re: box_293, Plugin unable to retrieve datastores informatio

Post by jyoti22 »

we use the service account that has read permissions on the top of the vcenter tree.
on VMA we have vi-admin account.

we use the below commands to add the service account for vcenter and do the plugin test. the below commands works fine

configure vma credentials for connecting to vcenter/esx
****************************************************************
vi-admin@vma:~> /usr/lib/vmware-vcli/apps/general/credstore_admin.pl add --server xx.xx.xx.xx--username "serviceaccount" --password "pwd"

Checking vcenter version from VMA
**************************************
vi-admin@vma:~> ~/box293_check_vmware.pl --server xx.xx.xx.xx --check vCenter_Name_Version


Plugin test from Nagios Host
*************************************
[nagios@Nagiosxi ~]$ /usr/local/nagios/libexec/check_by_ssh -E –t 30 1 -l vi-admin -H xx.xx.xx.xx -C "~/box293_check_vmware.pl --server xx.xx.xx.xx --check vCenter_Name_Version"


please give us the command to check if all permissions are in place.
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: box_293, Plugin unable to retrieve datastores informatio

Post by tgriep »

Another thing to try is to login to the vCenter server using the vi-admin username and password and see if you can see the datastores and the details of them using the VMWare Client.
Be sure to check out our Knowledgebase for helpful articles and solutions!
jyoti22
Posts: 254
Joined: Mon Mar 23, 2015 4:50 am

Re: box_293, Plugin unable to retrieve datastores informatio

Post by jyoti22 »

I am unable to login to vcenter with vi-admin credentials from vcenter client. PFA
You do not have the required permissions to view the files attached to this post.
monit_burb
Posts: 52
Joined: Fri Sep 23, 2016 3:00 am

Re: box_293, Plugin unable to retrieve datastores informatio

Post by monit_burb »

HI,

I have those checks installed and running fine. The only difference is that I don't have the --concurrent_checks option but the rest is the same. You can also test running the check manually from the vma command line
Locked