Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cisco_telemetry_mdt input plugin incorrect parsing of data sent by sensor "Cisco-IOS-XR-qos-ma-oper:qos/interface-table/interface/input/service-policy-names/service-policy-instance/statistics" #6322

Closed
marioullio opened this issue Aug 28, 2019 · 4 comments
Labels
bug unexpected problem or unintended behavior
Milestone

Comments

@marioullio
Copy link

Relevant telegraf.conf:

[[inputs.cisco_telemetry_mdt]]
 ## Telemetry transport can be "tcp" or "grpc".  TLS is only supported when
 # ## using the grpc transport.
   transport = "grpc"
 #
 #   ## Address and port to host telemetry listener
     service_address = "163.162.220.100:54321"

System info:

Operating system: redhat:enterprise_linux 7.6

Steps to reproduce:

  1. Cisco equipment details
    Cisco IOS XR Software, Version 6.6.25
    Copyright (c) 2013-2019 by Cisco Systems, Inc.
    Build Information:
    Built By : deenayak
    Built On : Wed May 29 06:42:35 PDT 2019
    Built Host : iox-lnx-030
    Workspace : /auto/srcarchive13/prod/6.6.25/ncs560/ws
    Version : 6.6.25
    Location : /opt/cisco/XR/packages/
    cisco NCS-560 () processor

  2. Relevant Cisco equipment configuration
    telemetry model-driven
    destination-group DGroup1
    address-family ipv4 163.162.220.100 port 54321
    encoding self-describing-gpb
    protocol grpc no-tls
    !
    !
    sensor-group SGroup
    sensor-path Cisco-IOS-XR-qos-ma-oper:qos/interface-table/interface/input/service-policy-names/service-policy-instance/statistics
    !
    subscription Sub1
    sensor-group-id SGroup sample-interval 300000
    destination-id DGroup1
    source-interface Loopback0
    !

  3. Send the telegraf output to file

Expected behavior:

All the metrics included in the output of Pipeline Collector (see dump.pipeline.txt) are also included in Telegraf output.

dump.pipeline.txt

Actual behavior:

In the Telegraf output only the "default class" metrics are included. It seems that Telegraf is not understanding correctly that "class-stats_PIPELINE_EDIT" is an array.

dump.telegraf.txt

Additional info:

@marioullio marioullio changed the title Incorrect parsing of cisco_telemetry_mdt input plugin of data sent by sensor "Cisco-IOS-XR-qos-ma-oper:qos/interface-table/interface/input/service-policy-names/service-policy-instance/statistics" Cisco_telemetry_mdt input plugin incorrect parsing of data sent by sensor "Cisco-IOS-XR-qos-ma-oper:qos/interface-table/interface/input/service-policy-names/service-policy-instance/statistics" Aug 28, 2019
@sbyx
Copy link
Contributor

sbyx commented Aug 28, 2019

The problem seems to be that the device does not declare the class-name to be a key therefore the telegraf plugin doesnt know to differentiate the measurements.

Does it make a difference if you change the subscription from "Cisco-IOS-XR-qos-ma-oper:qos/interface-table/interface/input/service-policy-names/service-policy-instance/statistics" to "Cisco-IOS-XR-qos-ma-oper:qos/interface-table/interface/input/service-policy-names/service-policy-instance/statistics/class_stats"?

@danielnelson danielnelson added the bug unexpected problem or unintended behavior label Aug 28, 2019
@marioullio
Copy link
Author

marioullio commented Aug 31, 2019 via email

@sbyx
Copy link
Contributor

sbyx commented Sep 17, 2019

There should be a changeset now merged that should allow you to specify the extra key-field so that the nested structure is parsed corretly. See the embedded_keys option in latest commits.

@yoplin
Copy link

yoplin commented May 18, 2022

How did you fix this? We're having the exact same problem with telegraf version 1.22.4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug unexpected problem or unintended behavior
Projects
None yet
Development

No branches or pull requests

4 participants