The OpenTelemetry Collector for Windows is installed from an MSI package and runs as a service. Use the configuration on the Linux page with the Windows paths below.
- Download
otelcol-contrib_<version>_windows_x64.msifrom the releases page and install it (msiexec /i otelcol-contrib_0.164.0_windows_x64.msi /qn). It installs toC:\Program Files\OpenTelemetry Collector\and registers the service otelcol-contrib (starts automatically, runs as LocalSystem). - Enrol the host as shown above; the files are in
C:\ProgramData\netlens-agent\(readable for SYSTEM and Administrators only, which is who the service runs as). - Replace
C:\Program Files\OpenTelemetry Collector\config.yamlwith the configuration above, using these paths:
yaml
tls:
ca_file: C:\ProgramData\netlens-agent\ca.pem
cert_file: C:\ProgramData\netlens-agent\agent.crt
key_file: C:\ProgramData\netlens-agent\agent.key
4. Restart-Service otelcol-contrib. Errors are in the Windows Application event log (source otelcol-contrib).
5. Outbound: allow TCP 4318 from the server to Netlens. Nothing inbound is needed.
(The MSI’s service name, install folder and default configuration were read from the package itself; the collector was not run on Windows here. The PowerShell enrolment and renewal were run on PowerShell 7.4.)
Enrolling a Windows host is described on Set up Netlens and enrol a host.