jtimon icon indicating copy to clipboard operation
jtimon copied to clipboard

tag keys defined by user

Open psagrera opened this issue 5 years ago • 3 comments

is there any way in which I can define my own tag keys to be inserted into influxdb ?

Example:

I'm gathering data for interfaces sensor (see below config)

    {
        "host": "10.102.187.188",
        "port": 50051,
        "cid": "mac1",
        "paths": [{
            "path": "/junos/system/linecard/interface/",
            "freq": 10000
        }],
        "influx": {
            "server": "172.17.0.2",
            "port": 8086,
            "dbname": "juniper",
            "user": "juniper",
            "password": "juniper",
            "recreate": true,
            "measurement": "/interface_test/"
        },
    
        "log": {
            "file": "test.log"
        }
    }

I'd need "/interfaces/interface/state/parent_ae_name" as tagKey in order to be able of grouping by this field . I know this can be done in jti_openconfig_telemetry plugin just setting the variable str_as_tags = true , that will treat all strings as tags.

Regards

Pablo

psagrera avatar Nov 06 '18 12:11 psagrera

JTIMON does not support custom tagging. It is a good feature request, I will add it to the work list.

nileshsimaria avatar Nov 12 '18 16:11 nileshsimaria

Thank you very much Nilesh.

psagrera avatar Nov 15 '18 08:11 psagrera

hello

We use this chain : Telegraf --> influx --> grafana

We use on Telegraf:

Input : jti_openconfig_telemetry Ouput : influx

Currently Junos doesn't export AE statistic . We only have physical interface stats and for each physical interface on which ae this interface is a member. So we have two distinct paths :

  • /interfaces/interface/state/parent_ae_name = which gives us the ae interface on which is attached the physical interface
  • /interfaces/interface/state/counters/ = which gives us the traffic stats of physical interface

when telegraf exports to influx the collected data we don't have the parent_ae field/tag attached to the entries related to /interfaces/interface/state/counters/ even if we add the knob str_as_tags = true because the parent_ae_name field is not present on /interfaces/interface/state/counters/. So we could not convert it in tag.

Thus, it is difficult/impossible to simply aggregate the counters of several physical interfaces attached to a same AE

Is there an easy way to achieve that ? with jtimon ?

BR David

door7302 avatar May 09 '19 14:05 door7302