VMware Cloud Community
G0nz0UK
Enthusiast
Enthusiast

PowerCLI with Grafana possible?

Hello,

I'm very new to PowerCLI, but I've been asked to obtain 3 reports and wonder if there is an example website to help me?

1. List all VMs with snapshots older than 2 days, showing VM name, OS, snapshot size, any tags.

2 VMs assigned with a tag called "Testing" showing VM name, OS, current disk free space.

3. List all datastores, showing name, size and free space.

They want this in Grafana which is what we use for everything.  I already have a lot in there for vCenter using Telegraf but not the above as it needs deeper info.

I'm sure PowerCLI can do the above, but I need to either create these as CSV files somehow or even better would be to send these to SQL and query that, is this even possible?

Thanks

Reply
0 Kudos
5 Replies
scott28tt
VMware Employee
VMware Employee

Expect a moderator to move this to the PowerCLI area.

 


-------------------------------------------------------------------------------------------------------------------------------------------------------------

Although I am a VMware employee I contribute to VMware Communities voluntarily (ie. not in any official capacity)
VMware Training & Certification blog
Reply
0 Kudos
LucD
Leadership
Leadership

Yes, all possible.

But are you looking for scripts retrieving that information?
Or are you looking for a way to upload this data and display it in a Grafana dashboard?

Asking for multiple scripts (3) in one thread, without even giving the code you already have, seems to be stretching the concept of a thread in a community a bit imho.


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

Reply
0 Kudos
G0nz0UK
Enthusiast
Enthusiast

ok

Reply
0 Kudos
G0nz0UK
Enthusiast
Enthusiast

I think I can would out how to write teh PowerCLI and Grafana is already, so it's how I get a PowerCLI into Grafana really.

Reply
0 Kudos
LucD
Leadership
Leadership

Reply
0 Kudos