vmware_exporter icon indicating copy to clipboard operation
vmware_exporter copied to clipboard

Is it possible to collect folder stats?

Open cihantunali opened this issue 4 years ago • 3 comments

Hello!

Is it possible to collect "Folder" name and its infos? Here is an example screen shot; image

I need to collect below items, is it possible? If yes, can you please guide me?

  • Folder name
  • Virtual machine count of Folder have
  • Folder's CPU usage
  • Folder's MEM usage
  • Folder's Storage usage

cihantunali avatar Nov 23 '20 08:11 cihantunali

Ill need to think on this one for a bit. I'm not sure I want this functionality built in. I feel it might be better to use tags or labels directly at the vm label to get this information.

pryorda avatar Nov 30 '20 07:11 pryorda

Hi @pryorda, I can get informations for each server but It is too hard to label or group these informations. For example my naming conversation like : customername_customerservertype_servernumber_ , example : cisco_IIS_server023 . With this information i can get below infos from Vcenter folder windows as mentioned.

Folder name : cisco Virtual machine count of Folder have : 23 Folder's CPU usage : 320 Folder's MEM usage : 90657 Folder's Storage usage : 2984.44

From prometheus, I can collect cisco_IIS_server023's informations(CPU usage, MEM usage etc) But I could not label/group the to customer name.

Here is my example query : label_replace(vmware_vm_cpu_usagemhz_average, "servicegroup", "$1", "vm_name", "(.+)_.+")

I could not get first word before _ because it did not accept regex (correct one is [:<:] )

So with all these information, it is really hard to collect needed data. Is there any chance to improve exporter to get them?

cihantunali avatar Dec 01 '20 09:12 cihantunali

We welcome PRs, but I will not be working on this feature in the near future.

pryorda avatar Mar 11 '21 20:03 pryorda