[[inputs.gnmi.subscription]]
## Name of the measurement that will be emitted
name = "event-stats"
## Origin and path of the subscription
origin = "openconfig-system"
path = "/system/event-stats"
## Subscription mode ("target_defined", "sample", "on_change") and interval
subscription_mode = "on_change"
heartbeat_interval = "5m"
Logs from Telegraf
admin@switch-3:/var/tmp$ ./telegraf --debug --config telegraf-8.conf
2024-06-21T04:00:14Z I! Loading config: telegraf-8.conf
2024-06-21T04:00:14Z I! Starting Telegraf 1.29.2 brought to you by InfluxData the makers of InfluxDB
2024-06-21T04:00:14Z I! Available plugins: 241 inputs, 9 aggregators, 30 processors, 24 parsers, 60 outputs, 6 secret-stores
2024-06-21T04:00:14Z I! Loaded inputs: gnmi
2024-06-21T04:00:14Z I! Loaded aggregators:
2024-06-21T04:00:14Z I! Loaded processors:
2024-06-21T04:00:14Z I! Loaded secretstores:
2024-06-21T04:00:14Z I! Loaded outputs: influxdb_v2
2024-06-21T04:00:14Z I! Tags enabled: host=switch-3
2024-06-21T04:00:14Z I! [agent] Config: Interval:10s, Quiet:false, Hostname:"switch-3", Flush Interval:10s
2024-06-21T04:00:14Z D! [agent] Initializing plugins
2024-06-21T04:00:14Z D! [inputs.gnmi] Internal alias mapping: map[openconfig-system:/system/event-stats:event-stats]
2024-06-21T04:00:14Z D! [agent] Connecting outputs
2024-06-21T04:00:14Z D! [agent] Attempting connection to [outputs.influxdb_v2]
2024-06-21T04:00:14Z D! [agent] Successfully connected to outputs.influxdb_v2
2024-06-21T04:00:14Z D! [agent] Starting service inputs
2024-06-21T04:00:14Z D! [inputs.gnmi] Connection to gNMI device 127.0.0.1:8080 established
2024-06-21T04:00:14Z D! [inputs.gnmi] Got update_1718942414831832038: {"update":{"timestamp":"1718942414831832038", "prefix":{"elem":[{"name":"openconfig-system:system"}, {"name":"openconfig-events:event-stats"}, {"name":"state"}]}, "update":[{"path":{"elem":[{"name":"acked"}]}, "val":{"uintVal":"0"}}, {"path":{"elem":[{"name":"cleared"}]}, "val":{"uintVal":"0"}}, {"path":{"elem":[{"name":"events"}]}, "val":{"uintVal":"4"}}, {"path":{"elem":[{"name":"raised"}]}, "val":{"uintVal":"0"}}]}}
2024-06-21T04:00:14Z D! [inputs.gnmi] No measurement alias for gNMI path: openconfig-system:/system/openconfig-events:event-stats/state/acked
2024-06-21T04:00:14Z W! [inputs.gnmi] Got empty metric-name for response, usually indicating
configuration issues as the response cannot be related to any subscription.
Please open an issue on https://github.com/influxdata/telegraf including your
device model and the following response data:
timestamp:1718942414831832038 prefix:{elem:{name:"openconfig-system:system"} elem:{name:"openconfig-events:event-stats"} elem:{name:"state"}} update:{path:{elem:{name:"acked"}} val:{uint_val:0}} update:{path:{elem:{name:"cleared"}} val:{uint_val:0}} update:{path:{elem:{name:"events"}} val:{uint_val:4}} update:{path:{elem:{name:"raised"}} val:{uint_val:0}}
This message is only printed once.
2024-06-21T04:00:14Z D! [inputs.gnmi] No measurement alias for gNMI path: openconfig-system:/system/openconfig-events:event-stats/state/cleared
2024-06-21T04:00:14Z D! [inputs.gnmi] No measurement alias for gNMI path: openconfig-system:/system/openconfig-events:event-stats/state/events
2024-06-21T04:00:14Z D! [inputs.gnmi] No measurement alias for gNMI path: openconfig-system:/system/openconfig-events:event-stats/state/raised
2024-06-21T04:00:14Z D! [inputs.gnmi] Got update_0: {"syncResponse":true}
2024-06-21T04:00:26Z E! [outputs.influxdb_v2] Failed to write metric to 50a05e37acb48a1a (will be dropped: 400 Bad Request): invalid: failed to parse line protocol: empty write payload
2024-06-21T04:00:26Z D! [outputs.influxdb_v2] Wrote batch of 1 metrics in 1.287549863s
2024-06-21T04:00:26Z D! [outputs.influxdb_v2] Buffer fullness: 0 / 10000 metrics
2024-06-21T04:00:34Z D! [outputs.influxdb_v2] Buffer fullness: 0 / 10000 metrics
2024-06-21T04:00:44Z D! [outputs.influxdb_v2] Buffer fullness: 0 / 10000 metrics
2024-06-21T04:00:54Z D! [outputs.influxdb_v2] Buffer fullness: 0 / 10000 metrics
^C2024-06-21T04:00:55Z D! [agent] Stopping service inputs
2024-06-21T04:00:55Z D! [inputs.gnmi] Connection to gNMI device 127.0.0.1:8080 closed
2024-06-21T04:00:55Z D! [agent] Input channel closed
2024-06-21T04:00:55Z I! [agent] Hang on, flushing any cached metrics before shutdown
2024-06-21T04:00:55Z D! [outputs.influxdb_v2] Buffer fullness: 0 / 10000 metrics
2024-06-21T04:00:55Z I! [agent] Stopping running outputs
2024-06-21T04:00:55Z D! [agent] Stopped Successfully
admin@switch-3:/var/tmp$
System info
Telegraf 1.29.2
Docker
No response
Steps to reproduce
Subscribe to gNMI target
Get response listed
Expected behavior
Telegraf can successfully subscribe to the gNMI path
Actual behavior
Telegraf cannot successfully subscribe to the gNMI path
Additional info
Other paths work without problems (e.g.: /system/alarm-stats)
Relevant telegraf.conf
Logs from Telegraf
System info
Telegraf 1.29.2
Docker
No response
Steps to reproduce
Expected behavior
Telegraf can successfully subscribe to the gNMI path
Actual behavior
Telegraf cannot successfully subscribe to the gNMI path
Additional info
Other paths work without problems (e.g.: /system/alarm-stats)