# Json data logging has strange behaviour

**URL:** https://discuss.elastic.co/t/json-data-logging-has-strange-behaviour/200852
**Category:** Beats
**Tags:** filebeat
**Created:** [September 24, 2019, 11:21am UTC](https://discuss.elastic.co/t/json-data-logging-has-strange-behaviour/200852 "2019-09-24T11:21:50Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Monu\_Kumar](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/monu_kumar/32/54790_2.png) [@Monu\_Kumar](https://discuss.elastic.co/u/Monu_Kumar)
#### Post date: [September 24, 2019, 11:21am UTC](https://discuss.elastic.co/t/json-data-logging-has-strange-behaviour/200852/1 "2019-09-24T11:21:50Z")

</div>

I'm using filebeat to send JSON logs to elasticsearch-\>kibana.  
Here is my filebeat.inputs config params:

```
    filebeat.inputs:
    - type: log
      enabled: true
      paths:
        - /home/ubuntu/testlog.* 
      json.keys_under_root: true
      json.add_error_key: true
      json.overwrite_keys: true
      ignore_decoding_error: true

```

The following json log is not sent to elasticsearch:  
{"name":{"f\_name":"john","l\_name":"d"}}

But when I change the key "name" to something like "name1" as following:  
{"name1":{"f\_name":"john","l\_name":"d"}}

It works.

I wonder if there are any conflicts? If yes I should be able to see that in filebeat log but even that doesn't have any info on that. I'm looking for filebeats under /var/log/filebeat/filebeat but I can't see any Error.

Few more Json structures that works fine:  
{"name":"john"}  
{"name":"john", "email":"xyz"}

---

<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: [October 22, 2019, 11:21am UTC](https://discuss.elastic.co/t/json-data-logging-has-strange-behaviour/200852/2 "2019-10-22T11:21:51Z")

</div>

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