doca-telemetry

Read DOCA hardware counters from a doca_dev via per-domain Telemetry reader libraries.

3.2k|370|Updated Feb 25, 2026
One-click install
npx skills add https://github.com/NVIDIA/skills --skill doca-telemetry
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: doca-telemetry
Source: https://github.com/NVIDIA/skills/tree/main/skills/doca-telemetry
Command: npx skills add https://github.com/NVIDIA/skills --skill doca-telemetry

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Developers building applications on NVIDIA BlueField DPUs or ConnectX NICs need to read hardware counters (PCC, DPA, diagnostics, adaptive retransmit, PHY, PCI) from a doca_dev, but the six per-domain DOCA Telemetry reader libraries each have their own headers, context types, capability queries, and lifecycle rules that are easy to misuse.

Core Features & Use Cases

  • Per-domain reader guidance: Covers the six sub-libraries (doca_telemetry_pcc, _dpa, _diag, _adp_retx, _phy, _pci), including capability queries, context creation, start, read, stop, and destroy lifecycles.
  • Error taxonomy and debugging: Maps DOCA_ERROR_* returns (NOT_SUPPORTED, AGAIN, BAD_STATE, INVALID_VALUE, NOT_PERMITTED, IO_FAILED) to reader-specific root causes and fixes.
  • Reader vs exporter disambiguation: Prevents the common first-app failure of confusing this counter-reader library with the sibling doca-telemetry-exporter publishing library.
  • Use Case: A developer asks their agent to "read PCC counters from my BlueField app" and receives step-by-step guidance to cap-query the device, create the doca_telemetry_pcc context, start it, and read counters with correct sample-window retry behavior.

Quick Start

Ask your agent to read PHY or PCC hardware counters from a doca_dev on your BlueField DPU using the DOCA Telemetry reader library.

Frequently Asked Questions about doca-telemetry

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I read DOCA hardware counters from a doca_dev?

Query the per-domain capability with doca_telemetry_<domain>_cap_is_supported(devinfo), create the context with doca_telemetry_<domain>_create on an open doca_dev, apply domain setters, call _start, then issue the per-domain read call. Finish with _stop and _destroy.

What is the difference between doca-telemetry and doca-telemetry-exporter?

doca-telemetry is the reader library that reads hardware counters off a doca_dev inside your application. doca-telemetry-exporter is the sibling publisher library for emitting labeled metrics or OTLP logs to a monitoring pipeline; they are separate libraries with separate pkg-config modules.

Why does doca_telemetry cap_is_supported return DOCA_ERROR_NOT_SUPPORTED?

NOT_SUPPORTED means the device does not expose that counter domain on this install, such as DPA on non-DPA devices or PHY sub-areas gated by firmware features. It is the capability answer, not a bug; surface it rather than retrying.

Why does my DOCA Telemetry read return DOCA_ERROR_AGAIN?

AGAIN means the hardware counter snapshot or sample cycle is not ready yet. Retry after the documented sample window (for diag, after the previous sampling cycle completes) instead of spinning in a tight loop.

Does doca-telemetry support NetFlow or IPFIX collectors?

No. The per-domain reader libraries expose no NetFlow, IPFIX, or local-socket collector surface. Use doca-telemetry-exporter for publishing, the productized DOCA Telemetry Service for aggregation, or a generic collector outside the DOCA family.

Can I use DOCA Telemetry from Rust, Go, or Python?

Yes, through FFI or language-specific bindings against the same shared libraries, since the canonical surface is the per-domain C API. The cap-query-first discipline, lifecycle ordering, and error handling rules apply identically in any wrapper language.