# Ailed to parse field \[host\] of type \[text\] in document with id

**URL:** https://discuss.elastic.co/t/ailed-to-parse-field-host-of-type-text-in-document-with-id/278963
**Category:** Logstash
**Created:** [July 17, 2021, 9:43am UTC](https://discuss.elastic.co/t/ailed-to-parse-field-host-of-type-text-in-document-with-id/278963 "2021-07-17T09:43:07Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Bhuwaneshwar](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/bhuwaneshwar/32/91775_2.png) [@Bhuwaneshwar](https://discuss.elastic.co/u/Bhuwaneshwar)
#### Post date: [July 17, 2021, 9:43am UTC](https://discuss.elastic.co/t/ailed-to-parse-field-host-of-type-text-in-document-with-id/278963/1 "2021-07-17T09:43:07Z")

</div>

Dear Team

I am getting below error on Logstash.

"error"=\>{"type"=\>"mapper\_parsing\_exception", "reason"=\>"failed to parse field [host] of type [text] in document with id '4qrUs3oBqKFEAtQHASue'. Preview of field's value: '{hostname=Gauri, os={build=19042.1083, kernel=10.0.19041.1083 (WinBuild.160101.0800), name=Windows 10 Home, type=windows, family=windows, version=10.0, platform=windows}, ip=[fe80::a4a0:65da:2279:abe6, 169.254.171.230, 192.168.10.169, fe80::64d5:dcba:bc1f:39a2, 169.254.57.162, fe80::b8f1:2cd9:84bd:4d07, 169.254.77.7, fe80::5554:5fcb:378a:2a9d, 169.254.42.157, fe80::5065:4bd7:d551:169e, 169.254.22.158, 2001:8f8:172d:ab3d::1000, 2001:8f8:172d:ab3d:4d52:fa49:b16:f18a, 2001:8f8:172d:ab3d:88f8:3b82:c4be:aec2, 2001:8f8:172d:ab3d:8985:ef1:7abc:fe56, 2001:8f8:172d:ab3d:8d38:e24c:9de:51b4, 2001:8f8:172d:ab3d:b433:67de:514:1f63, 2001:8f8:172d:ab3d:b89e:b0f6:41d4:94e2, fe80::4d52:fa49:b16:f18a, 192.168.1.13], name=Gauri, id=e97c350a-4869-4831-9ef3-5eb2930884e3, mac=[e4:e7:49:82:0d:86, 00:ff:68:32:9b:47, 2a:3a:4d:8d:d1:9d, aa:3a:4d:8d:d1:9d, 00:09:0f:fe:00:01, 28:3a:4d:8d:d1:9d], architecture=x86\_64}'", "caused\_by"=\>{"type"=\>"illegal\_state\_exception", "reason"=\>"Can't get text on a START\_OBJECT at 1:377"}}}}}

Logstash.conf entry

```auto
# Read input from filebeat by listening to port 5044 on which filebeat will send the data
input {
    beats {
	    type => "test"
        port => "5044"
    }
}
 
filter {
  #If log line contains tab character followed by 'at' then we will tag that entry as stacktrace
  if [message] =~ "\tat" {
    grok {
      match => ["message", "^(\tat)"]
      add_tag => ["stacktrace"]
    }
  }
 
}
 
output {
   
  stdout {
    codec => rubydebug
  }
 
  # Sending properly parsed log events to elasticsearch
  elasticsearch {
    hosts => ["localhost:9200"]
  }
}

```

---

<div class="post-metadata">

### Author: ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)
#### Post date: [July 17, 2021, 6:05pm UTC](https://discuss.elastic.co/t/ailed-to-parse-field-host-of-type-text-in-document-with-id/278963/2 "2021-07-17T18:05:00Z")

</div>

> [@Bhuwaneshwar](#):
>
> mapper\_parsing\_exception

There are many explanations of this in this forum. [Here](https://discuss.elastic.co/t/encountered-mapper-parsing-exception-when-working-through-logstash-tutorial/173746/2) for example. See also [here](https://discuss.elastic.co/t/problem-logstash-outputs-elasticsearch-could-not-index-event-to-elasticsearch-wazuh-alerts-3-x-2020-05-30/235038/6).

---

<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: [August 14, 2021, 6:05pm UTC](https://discuss.elastic.co/t/ailed-to-parse-field-host-of-type-text-in-document-with-id/278963/3 "2021-08-14T18:05:53Z")

</div>

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