influxdata / telegraf

Agent for collecting, processing, aggregating, and writing metrics, logs, and other arbitrary data.
https://influxdata.com/telegraf
MIT License
14.5k stars 5.55k forks source link

Remote host WMI collection capabilty in the win_wmi plugin #14942

Closed shockogit closed 6 months ago

shockogit commented 6 months ago

Use Case

The ability for the WMI plugin https://github.com/influxdata/telegraf/blob/9a9bb16c08adab133f2d995d6e26bdad130999ef/plugins/inputs/win_wmi/win_wmi.go#L1 to collect data from a remote host.

Expected behavior

The ability to specify a remote host(s) to gather WMI data from

Actual behavior

Only local host is supported so agent must run on host. No agentless capability.

Additional info

WMI is generally a datastore accessed remotely by numerous native windows tools. Seems logical to add this feature.

powersj commented 6 months ago

Hi,

I had some déjà vu thinking we already did this, but https://github.com/influxdata/telegraf/pull/12556 was about win_perf_counters.

Let me talk to folks about this tomorrow. It seems this has come up before.

powersj commented 6 months ago

Sven is going to look into doing this. This should be similar to what we have for win_perf_counters in terms of auth, and does mean that this would only be available from a windows machine to a windows machine.

shockogit commented 6 months ago

It would be super useful. For windows, I find myself more and more gathering the win_perf_counters input remotely. I have several use cases for wmi, in particular the Citrix EUEM metrics.

srebhan commented 6 months ago

@shockogit please test the binary in #14973 and let me know if it works for your use-case!

shockogit commented 6 months ago

@shockogit please test the binary in #14973 and let me know if it works for your use-case!

Works perfectly!