Error message with MQTT and JSON

spider53
Tue, 27 Feb 2024 08:30:25 +0000
Telegraf

Hello,

I have a quit simple config file to write two values into InfluxDB. It works ok since 2 month and writes the two values “Zaehler_Stand” and “Zaeler_Verbrauch” into the database. But nevertheless I have continuously error messages and I do not know why. Has anyone an idea?
Thanks for your help.

MQTT Input
{
“Time” : “2023-11-09T17:36:37”,
“Main” : {
“power” : 519,
“counter” : 17060.773
}
}

telegraf config

###############################################################################

INPUT PLUGINS

###############################################################################

[[inputs.mqtt_consumer]]
servers = [“tcp://192.xxx.xxx.xx:1883”]
name_override = “Hichi”

topics = [“tele/tasmota/#”]

data_format = “json_v2”

[[inputs.mqtt_consumer.topic_parsing]]
topic = “tele/tasmota/Hichi/SENSOR”

[[inputs.mqtt_consumer.json_v2]]
[[inputs.mqtt_consumer.json_v2.field]]
path = “Main.power”
rename = “Zaehler_Verbrauch”
type = “int”
[[inputs.mqtt_consumer.json_v2.field]]
path = “Main.counter”
rename = “Zaehler_Stand”
type = “float”

Error messages

Feb 25 11:01:05 Raspi4 telegraf[552]: 2024-02-25T11:01:05Z D! [outputs.influxdb_v2] Buffer fullness: 0 / 10000 metrics
Feb 25 11:01:06 Raspi4 telegraf[552]: 2024-02-25T11:01:06Z D! [outputs.file] Buffer fullness: 0 / 10000 metrics
Feb 25 11:01:07 Raspi4 telegraf[552]: 2024-02-25T11:01:07Z D! [parsers.json_v2::mqtt_consumer] the path “Main.power” doesn’t exist
Feb 25 11:01:07 Raspi4 telegraf[552]: 2024-02-25T11:01:07Z E! [inputs.mqtt_consumer] Error in plugin: the path “Main.power” doesn’t exist
Feb 25 11:01:07 Raspi4 telegraf[552]: 2024-02-25T11:01:07Z D! [parsers.json_v2::mqtt_consumer] the path “Main.power” doesn’t exist

4 posts - 2 participants