Open
Description
Current Behavior
The collector for the services fails. In the eventlog, i can see message like these:
time=2025-02-11T08:50:56.421Z level=WARN source=collect.go:212 msg="collector service failed after 5.3143ms, resulting in 0 metrics" err="failed to query all services: The data is invalid."
We have configured a config.yml file and exclude most of the services.
This is the config file
scrape:
timeout-margin: 0.5
telemetry:
max-requests: 5
path: /metrics
log:
level: warn
collector:
scheduled_task:
exclude: /Microsoft/.+
service:
include: sshd|Certificate Enrollment System|WdNisSvc|WinDefend|Splunkd|osqueryd
collectors:
enabled: cpu,cpu_info,diskdrive,license,logical_disk,logon,memory,net,os,pagefile,scheduled_task,service,system,terminal_services,update,textfile
web:
listen-address: :9182
Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\windows_exporter ImagePath:
"C:\Program Files\windows_exporter\windows_exporter.exe" --config.file="C:\Program Files\windows_exporter\config.yml"
Expected Behavior
The collector should not crash.
Steps To Reproduce
Environment
- windows_exporter Version: 0.30.2
- Windows Server Version: Several versions.. Windows Server 2019/2022/2025 Windows 10 and 11
windows_exporter logs
time=2025-02-11T08:50:56.421Z level=WARN source=collect.go:212 msg="collector service failed after 5.3143ms, resulting in 0 metrics" err="failed to query all services: The data is invalid."
Anything else?
No response