Prometheus Metrics

Hello,

We have a Prometheus and Grafana server on our Company. We have see that the Prometheus server scrape a lot of metrics (from the windows exporter default installation). We need to reduce the metrics that it colect. i have try to find some aswer but it’s not really clear. did someone can tell how to define the metric to collect on the Prometheus server. We use YML config file and JSON files to define the targets.
regards,

Welcome

Can you please share your exporter config?

Hello,
I haven’t install the exporter so i don’t know how to find the config. can you tell me how to do this?
Regards,

Which windows host is the windows exporter installed on? And who installed it?

It’s a windows server 2019 standard. it’s an IT guy who installed it but i think he just do the default installation.

Please share the config file they used on that host

We use the Exe file windows_exporter but i don’t think they use a config file to the installation on this host. Or you talk about the YML files on the prometheus server?
Regards,

you could simply check and see if there is a config file.

Anyways, if you do not use config file like this one redacted one that specifies which collectors it captures, it probably captures everything and it is a lot! Look at collectors section here GitHub - prometheus-community/windows_exporter: Prometheus exporter for Windows machines

collectors:
  enabled: cpu,cs,logical_disk,net,os,service,system,textfile

Thanks for your reply. As i see the windows exporter we use only collect default collector.
Can you tell me if you have more explanation to write the config files.

Just read the documentation cause it depends what you want to collect

Hello i have already resd this document. But i don’t know how to collect only metrics from a specific collector.
For example i just need to expose the windows_cpu_time_total from the CPU collector.
How can i do this? did i have to use a config file when we install the windows exporter or did we have to do his on the prometheus server?
Regards,