Deploy and verify model-driven telemetry
5.3.d i Configure on-change subscription using gRPC
google Remote Procedure Call
General information on “Model-driven telemetry (MDT) on-change subscription using gRPC”:
- Model-driven telemetry (MDT) uses a push-model to stream YANG-modelled data to a collector (like NetFlow) which allows for near real-time access to operational statistics for monitoring data
- MDT updates can be configured in two ways:
- periodic: Updates are pushed to the collectors every x seconds.
- on-change: Updates are only pushed to the collector when a change occurs.
- MDT provides network operators with additional options for getting information from their network
- MDT provides an additional interface in which telemetry is now available to be published from
- MDT addresses many of the SNMP shortfalls such as unreliable transport, inconsistent encoding, …
- gRPC is a high performance, open-source universal RPC framework
- gRPC is used to transport YANG-modeled data from the IOS XE device to a 3rd party collector/receiver
- MDT with gRPC only supports the following configuration:
- Dial-out streaming via grpc-tcp
- YANG-push as stream
- Encoding with kvGPB (Key-value Google Protocol Buffers)
- Configuration of MDT can be done either via CLI or via RESTCONF/NETCONF
- The XPath filter value is based on YANG models
- XPath filter construction: /[model-prefix]:[model-container]/[model-container-list]
“Model-driven telemetry on-change subscription using gRPC” CLI configuration commands:
## Mandatory MDT on-change subscription w/ gRPC
Router(config)# telemetry ietf subscription <id>
Router(config-mdt-subs)# encoding encode-kvgpb
Router(config-mdt-subs)# stream yang-push
Router(config-mdt-subs)# update-policy on-change
Router(config-mdt-subs)# receiver ip address <ip> <port> protocol grpc-tcp
## Optional MDT on-change subscription w/ gRPC
Router(config-mdt-subs)# filter xpath <xpath-filter>
“Model-driven telemetry on-change subscription using gRPC” CLI show commands:
## Show specific MDT subscription parameters
Router# show telemetry ietf subscription <id>
## Show all configured MDT subscriptions
Router# show telemetry ietf subscription <all>
MDT configuration using JSON (URI: /restconf/data/Cisco-IOS-XE-mdt-cfg:mdt-config-data):
{
"mdt-subscription": [
{
"subscription-id": "<id>",
"base": {
"stream": "yang-push",
"encoding": "encode-kvgpb",
"no-synch-on-start": false,
"xpath": "<filter>"
},
"mdt-receivers": [
{
"address": "<ip>",
"port": "<port>",
"protocol": "grpc-tcp"
}
]
}
]
}