Telemetry Model Driven
Configure model-driven telemetry on IOS-XR devices including sensor groups, destination groups, and subscriptions for streaming telemetry data via gRPC, TCP, or UDP protocols. Sensor groups define the YANG paths to collect, destination groups specify where to send the data, and subscriptions bind sensor groups to destinations with collection parameters.
Diagram
Section titled “Diagram”Classes
Section titled “Classes”configuration (iosxr.devices)
Section titled “configuration (iosxr.devices)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| telemetry_model_driven | Class | [telemetry_model_driven] | No |
telemetry_model_driven (iosxr.devices.configuration)
Section titled “telemetry_model_driven (iosxr.devices.configuration)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| destination_groups | List | [destination_groups] | No | |
| gnmi | Class | [gnmi] | No | |
| include_empty_values | Boolean | true, false | No | |
| include_select_leaves_on_events | Boolean | true, false | No | |
| max_containers_per_path | Integer | min: 0, max: 1024 | No | |
| max_sensor_paths | Integer | min: 0, max: 4000 | No | |
| sensor_groups | List | [sensor_groups] | No | |
| strict_timer | Boolean | true, false | No | |
| subscriptions | List | [subscriptions] | No | |
| tcp_send_timeout | Integer | min: 0, max: 30 | No |
destination_groups (iosxr.devices.configuration.telemetry_model_driven)
Section titled “destination_groups (iosxr.devices.configuration.telemetry_model_driven)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| name | String | Yes | ||
| destinations | List | [destinations] | No | |
| vrf | String | No |
gnmi (iosxr.devices.configuration.telemetry_model_driven)
Section titled “gnmi (iosxr.devices.configuration.telemetry_model_driven)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| bundling | Boolean | true, false | No | |
| bundling_size | Integer | min: 1, max: 65535 | No | |
| heartbeat_always | Boolean | true, false | No | |
| target_defined_cadence_factor | Integer | min: 1, max: 20 | No | |
| target_defined_minimum_cadence | Integer | min: 1, max: 65535 | No |
sensor_groups (iosxr.devices.configuration.telemetry_model_driven)
Section titled “sensor_groups (iosxr.devices.configuration.telemetry_model_driven)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| name | String | Yes | ||
| sensor_paths | List | [sensor_paths] | No |
subscriptions (iosxr.devices.configuration.telemetry_model_driven)
Section titled “subscriptions (iosxr.devices.configuration.telemetry_model_driven)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| name | String | Yes | ||
| destination_ids | List | [destination_ids] | No | |
| send_retry | Integer | min: 0, max: 4294967295 | No | |
| send_retry_duration | Integer | min: 0, max: 4294967295 | No | |
| sensor_group_ids | List | [sensor_group_ids] | No | |
| source_interface | String | No | ||
| source_qos_marking | Choice | af11, af12, af13, af21, af22, af23, af31, af32, af33, af41, af42, af43, cs1, cs2, cs3, cs4, cs5, cs6, cs7, default, ef | No |
destinations (iosxr.devices.configuration.telemetry_model_driven.destination_groups)
Section titled “destinations (iosxr.devices.configuration.telemetry_model_driven.destination_groups)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| address | String | Yes | ||
| port | Integer | min: 1, max: 65535 | Yes | |
| address_family | Choice | ipv4, ipv6 | No | |
| encoding | Choice | json, self-describing-gpb, gpb | No | |
| grpc_gzip | Boolean | true, false | No | |
| grpc_no_tls | Boolean | true, false | No | |
| grpc_tls_hostname | String | No | ||
| protocol | Choice | grpc, tcp, udp | No | |
| udp_packetsize | Integer | min: 484, max: 65507 | No |
sensor_paths (iosxr.devices.configuration.telemetry_model_driven.sensor_groups)
Section titled “sensor_paths (iosxr.devices.configuration.telemetry_model_driven.sensor_groups)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| name | String | Yes |
destination_ids (iosxr.devices.configuration.telemetry_model_driven.subscriptions)
Section titled “destination_ids (iosxr.devices.configuration.telemetry_model_driven.subscriptions)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| name | String | Yes |
sensor_group_ids (iosxr.devices.configuration.telemetry_model_driven.subscriptions)
Section titled “sensor_group_ids (iosxr.devices.configuration.telemetry_model_driven.subscriptions)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| name | String | Yes | ||
| heartbeat_always | Boolean | true, false | No | |
| heartbeat_interval | Integer | min: 1, max: 4294967295 | No | |
| mode | Choice | target-defined | No | |
| sample_interval | Integer | min: 0, max: 4294967295 | No | |
| strict_timer | Boolean | true, false | No |
Data Normalization
Section titled “Data Normalization”Destination Address Detection
The destinations list accepts IPv4 addresses, IPv6 addresses, and hostnames in the address field. The Terraform module automatically detects the address type and routes entries to the appropriate. Hostname entries require an explicit address_family field (ipv4 or ipv6) to prefer a transport in the DNS response.
Protocol Routing
The protocol field accepts grpc, tcp, or udp. Protocol-specific attributes (grpc_no_tls, grpc_tls_hostname, grpc_gzip for gRPC; udp_packetsize for UDP) are only applied when the matching protocol is selected.
Example YAML Code:
Section titled “Example YAML Code:”Example-1: gRPC destination with interface counters.
iosxr: devices: - name: router-1 host: 10.10.10.1:57400 configuration: telemetry_model_driven: sensor_groups: - name: INTF-COUNTERS sensor_paths: - name: Cisco-IOS-XR-infra-statsd-oper:infra-statistics/interfaces/interface/latest/generic-counters destination_groups: - name: COLLECTOR-1 destinations: - address: 10.1.1.1 port: 57500 encoding: json protocol: grpc grpc_no_tls: true subscriptions: - name: SUB-INTF sensor_group_ids: - name: INTF-COUNTERS sample_interval: 30000 destination_ids: - name: COLLECTOR-1Example-2: Target-defined mode, GNMI tuning, and VRF.
iosxr: devices: - name: router-1 host: 10.10.10.1:57400 configuration: telemetry_model_driven: max_sensor_paths: 1000 gnmi: heartbeat_always: true bundling: true bundling_size: 1024 target_defined_cadence_factor: 5 target_defined_minimum_cadence: 60 sensor_groups: - name: BGP-NEIGHBORS sensor_paths: - name: Cisco-IOS-XR-ipv4-bgp-oper:bgp/instances/instance/instance-active/default-vrf/neighbors/neighbor destination_groups: - name: MONITORING vrf: MGMT destinations: - address: 172.16.0.100 port: 57500 encoding: self-describing-gpb protocol: grpc - address: "2001:db8:100::1" port: 57500 encoding: self-describing-gpb protocol: grpc grpc_gzip: true subscriptions: - name: SUB-BGP source_interface: Loopback0 source_qos_marking: ef sensor_group_ids: - name: BGP-NEIGHBORS mode: target-defined destination_ids: - name: MONITORINGExample-3: Hostname collector with UDP transport.
iosxr: devices: - name: router-1 host: 10.10.10.1:57400 configuration: telemetry_model_driven: sensor_groups: - name: PLATFORM-HEALTH sensor_paths: - name: Cisco-IOS-XR-wdsysmon-fd-oper:system-monitoring/cpu-utilization - name: Cisco-IOS-XR-nto-misc-oper:memory-summary/nodes/node/summary destination_groups: - name: DEST-UDP destinations: - address: collector.example.com address_family: ipv4 port: 57500 encoding: json protocol: udp udp_packetsize: 1024 subscriptions: - name: SUB-PLATFORM sensor_group_ids: - name: PLATFORM-HEALTH sample_interval: 60000 destination_ids: - name: DEST-UDP