Cisco Telemetry Explained & Configuration

Why do we need Telemetry:

Cisco NX-OS provides several mechanisms such as SNMP, CLI, and Syslog to collect data from a network. These mechanisms have limitations that restrict automation and scale. One limitation is the use of the pull model, where the initial request for data from network elements originates from the client. The pull model does not scale when there is more than one network management station (NMS) in the network. With this model, the server sends data only when clients request it. To initiate such requests, continual manual intervention is required. This continual manual intervention makes the pull model inefficient.

A push model continuously streams data out of the network and notifies the client. Telemetry enables the push model, which provides near-real-time access to monitoring data.

Cisco NX-OS streaming telemetry allows you to push data off the device to a defined endpoint as JavaScript Object Notation (JSON) or using Google Protocol Buffers (GPB) at a much higher frequency and more efficiently.

Telemetry Components and Process

Telemetry consists of four key elements:

  • Data Collection : Telemetry data is collected from the Data Management Engine (DME) database in branches of the object model specified using distinguished name (DN) paths. The data can be retrieved periodically (frequency-based) or only when a change occurs in any object on a specified path (event-based). You can use the NX-API to collect frequency-based data.
  • Data Encoding : The telemetry encoder encapsulates the collected data into the desired format for transporting.NX-OS encodes telemetry data in the Google Protocol Buffers (GPB) and JSON format.
  • Data Transport : NX-OS transports telemetry data using HTTP for JSON encoding and the Google remote procedure call (gRPC) protocol for GPB encoding. The gRPC receiver supports message sizes greater than 4 MB. (Telemetry data using HTTPS is also supported if a certificate is configured.)
  • Telemetry Receiver : A telemetry receiver is a remote management system or application that stores the telemetry data.



Guidelines and Restrictions for Telemetry

Telemetry has the following configuration guidelines and limitations:

  • Telemetry is supported in Cisco NX-OS releases starting from 7.0(3)I5(1) for releases that support the data management engine (DME) Native Model.
  • Release 7.0(3)I6(1) supports DME data collection, NX-API data sources, Google protocol buffer (GPB) encoding over Google Remote Procedure Call (gRPC) transport, and JSON encoding over HTTP.
  • The smallest sending interval (cadence) supported is five seconds for a depth of 0. The minimum cadence values for depth values greater than 0 depends on the size of the data being streamed out. Configuring cadences below the minimum value may result in undesirable system behavior.
  • Up to five remote management receivers (destinations) are supported. Configuring more than five remote receivers may result in undesirable system behavior.



Telemetry configuration on Nexus 9000:

Three simple steps are all that is required to configure telemetry:


Step 1. Set the format and destination to which the data is to be sent.
Step 2. Configure the data that is to be collected as part of the sensor group.
Step 3. Set the subscription between the sensor-group and the destination, along with the pace at which to send the data (in millseconds).

This example creates a cadence-based collection of show command data every 750 seconds.

switch(config)# telemetry
switch(config-telemetry)# destination-group 1
switch(conf-tm-dest)# ip address 172.27.247.72 port 60001 protocol gRPC encoding GPB 

switch(conf-tm-dest)# sensor-group 1
switch(conf-tm-sensor# data-source NX-API
switch(conf-tm-sensor)# path "show system resources" depth 0
switch(conf-tm-sensor)# path "show version" depth 0 
switch(conf-tm-sensor)# path "show environment power" depth 0 
switch(conf-tm-sensor)# path "show environment fan" depth 0 
switch(conf-tm-sensor)# path "show environment temperature" depth 0 
switch(conf-tm-sensor)# path "show process cpu" depth 0 
switch(conf-tm-sensor)# path "show nve peers" depth 0 
switch(conf-tm-sensor)# path "show nve vni" depth 0 
switch(conf-tm-sensor)# path "show nve vni 4002 counters" depth 0 
switch(conf-tm-sensor)# path "show int nve 1 counters" depth 0 
switch(conf-tm-sensor)# path "show policy-map vlan" depth 0 
switch(conf-tm-sensor)# path "show ip access-list test" depth 0 
switch(conf-tm-sensor)# path "show system internal access-list resource utilization" depth 0 

switch(conf-tm-sensor)# subscription 1
switch(conf-tm-sub)# dst-grp 1
switch(conf-tm-dest)# snsr-grp 1 sample-interval 750000Code language: PHP (php)

Bilel-A

Enthusiastic Network Engineer specializing in Cisco ACI, passionate about solving challenges. A lifelong learner who loves gaining and sharing knowledge. Profile: https://www.linkedin.com/in/bilel-ameur-71116b2b5
0 0 votes
Article Rating
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x