# Logstash filebeat json payload problem

**URL:** <https://discuss.elastic.co/t/logstash-filebeat-json-payload-problem/265237>\
**Category:** Logstash\
**Created:** [February 23, 2021, 5:30pm UTC](https://discuss.elastic.co/t/logstash-filebeat-json-payload-problem/265237 "2021-02-23T17:30:16Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![MMerel](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mmerel/32/76751_2.png) [@MMerel](https://discuss.elastic.co/u/MMerel)\
**Post date:** [February 23, 2021, 5:30pm UTC](https://discuss.elastic.co/t/logstash-filebeat-json-payload-problem/265237/1 "2021-02-23T17:30:16Z")

</div>

```auto
Hello everyone, I´m having trouble trying to parse simple json data from logstash to elasticsearch . My config is : 
filebeat suscribed to some mosquitto topic > logstash mqqt input > elasticsearch > kibana.
 @timestamp , mqtt topic and the message json payload structured in fields are my goals .
While I do get information I don´t see it well structured , i played with filebeat json processor , logstash input (json_lines) , logstash json filter , but got the best result with json codec . 
I'll post my config ,hoping someone can tell me what I'm missing . If you haven't noticed I´m really a newbie at ELK .

logstash config :

input {
	 beats {
        port => "5044"
		codec => "json"
    }
}

output {

		stdout { codec => rubydebug { metadata => true } }
		elasticsearch {
		hosts => ["http://localhost:9200"]
		index => "block"
		}
}

This is the output I´m getting , I see it organized , however ,back in kibana I don´t see the resulting fields . Do you guys validate this output and maybe I´m missing something in Elasticsearch???

{
           "input" => {
        "type" => "mqtt"
    },
           "agent" => {
            "hostname" => "DESKTOP-564O36T",
                "name" => "DESKTOP-564O36T",
                  "id" => "72b87c44-b538-4a3d-b195-f3f35824acf2",
                "type" => "filebeat",
        "ephemeral_id" => "5a1658fa-4bd4-4657-ba9d-4e2fba7357dd",
             "version" => "7.9.2"
    },
      "@timestamp" => 2021-02-23T17:22:16.663Z,
             "ecs" => {
        "version" => "1.5.0"
    },
       "@metadata" => {
        "ip_address" => "0:0:0:0:0:0:0:1",
              "beat" => "filebeat",
              "type" => "_doc",
           "version" => "7.9.2"
    },
            "mqtt" => {
          "retained" => false,
               "qos" => 0,
             "topic" => "Block/SalaN/Equipamiento",
        "message_id" => 0,
         "duplicate" => false
    },
        "@version" => "1",
            "host" => {
        "name" => "DESKTOP-564O36T"
    },
            "tags" => [
        [0] "beats_input_codec_json_applied"
    ],
    "Equipamiento" => {
        "Corriente" => 0.015769,
               "Id" => "12010-13402",
             "Unit" => "Amp"
    }
}

Thanks in any way you can help me .

```

---

<div class="post-metadata">

**Author:** ![aaron-nimocks](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/aaron-nimocks/32/73965_2.png) [@aaron-nimocks](https://discuss.elastic.co/u/aaron-nimocks)\
**Post date:** [February 24, 2021, 1:35pm UTC](https://discuss.elastic.co/t/logstash-filebeat-json-payload-problem/265237/2 "2021-02-24T13:35:48Z")

</div>

How are you verifying the data in Kibana?

In Dev Tools run `GET block/_search` to see if you have any data.

Also did you [create an index pattern](https://www.elastic.co/guide/en/kibana/current/index-patterns.html)? You can only see the data in Visualizations and Discover after you have done that.

---

<div class="post-metadata">

**Author:** ![MMerel](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mmerel/32/76751_2.png) [@MMerel](https://discuss.elastic.co/u/MMerel)\
**Post date:** [March 2, 2021, 4:15pm UTC](https://discuss.elastic.co/t/logstash-filebeat-json-payload-problem/265237/3 "2021-03-02T16:15:21Z")

</div>

Hi aaron , I gave up using filebeat because rabbitmq suits me better , configured the logstash plugin some filter and everything now works fine!!!

Thanks so much for your feedcabk.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [March 30, 2021, 4:15pm UTC](https://discuss.elastic.co/t/logstash-filebeat-json-payload-problem/265237/4 "2021-03-30T16:15:40Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
