# How to fix host issue in filebeat-7.17.4 without drop\_fields

**URL:** https://discuss.elastic.co/t/how-to-fix-host-issue-in-filebeat-7-17-4-without-drop-fields/306890
**Category:** Beats
**Tags:** filebeat
**Created:** [June 10, 2022, 12:47pm UTC](https://discuss.elastic.co/t/how-to-fix-host-issue-in-filebeat-7-17-4-without-drop-fields/306890 "2022-06-10T12:47:29Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![mbmannubisht](https://avatars.discourse-cdn.com/v4/letter/m/7993a0/32.png) [@mbmannubisht](https://discuss.elastic.co/u/mbmannubisht)
#### Post date: [June 10, 2022, 12:47pm UTC](https://discuss.elastic.co/t/how-to-fix-host-issue-in-filebeat-7-17-4-without-drop-fields/306890/1 "2022-06-10T12:47:29Z")

</div>

Hi Team,

Stuck in one issue if I drop\_fields of host then it will work otherwise not working

Working condition code:

```auto
  - drop_fields:
      fields: ["beat", "offset", "source", "type", "input_type", "host"]
      ignore_missing: true

```

Not Working condition code:

```auto
processors:
  - drop_fields:
      fields: ["beat", "offset", "source", "type", "input_type"]
      ignore_missing: true

```

Error is here :=\>

```auto
Could not index event to Elasticsearch.status: 400, action:
"type" => "mapper_parsing_exception", "reason" => "failed to parse field [host] of type [text] in document with id ''. Preview of field's value: '{name=hostname}'", "caused_by" => {
				"type" => "illegal_state_exception", "reason" => "Can't get text on a START_OBJECT at 1:468"

```

Please help on this

---

<div class="post-metadata">

### Author: ![mbmannubisht](https://avatars.discourse-cdn.com/v4/letter/m/7993a0/32.png) [@mbmannubisht](https://discuss.elastic.co/u/mbmannubisht)
#### Post date: [June 16, 2022, 7:21am UTC](https://discuss.elastic.co/t/how-to-fix-host-issue-in-filebeat-7-17-4-without-drop-fields/306890/2 "2022-06-16T07:21:17Z")

</div>

I'm not getting any response back from Elasticsearch community also if someone worked before on filebeat configuration please let me know

---

<div class="post-metadata">

### Author: ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)
#### Post date: [June 16, 2022, 8:17am UTC](https://discuss.elastic.co/t/how-to-fix-host-issue-in-filebeat-7-17-4-without-drop-fields/306890/3 "2022-06-16T08:17:00Z")

</div>

> [@mbmannubisht](#):
>
> `Can't get text on a START_OBJECT`

> [@mbmannubisht](#):
>
> `Preview of field's value: '{name=hostname}'`

Can you check the `<indexname>/_mapping/host` endpoint in Elasticsearch and see what it gives back? It looks like something has gone wrong there.

---

<div class="post-metadata">

### Author: ![mbmannubisht](https://avatars.discourse-cdn.com/v4/letter/m/7993a0/32.png) [@mbmannubisht](https://discuss.elastic.co/u/mbmannubisht)
#### Post date: [June 17, 2022, 4:51am UTC](https://discuss.elastic.co/t/how-to-fix-host-issue-in-filebeat-7-17-4-without-drop-fields/306890/4 "2022-06-17T04:51:43Z")

</div>

**Here are few more problems in Filebeat:**

I'm using `output.kafka:` and it never allowed me to send custom host fields inside `filebeat.inputs:` due to this I'm blocked to pass host name.

Second problem, I can ignore host problem but I can't run two YML file in one beat and it send through this ERROR

```auto
Exiting: data path already locked by another beat. Please make sure that multiple beats are not sharing the same data path (path.data).

```

To overcome this problem, I tired to merge two YML file into one using `filebeat.config.inputs:` but it won't work in my case.  
below is the module details

```auto
filebeat.config.inputs:
  enabled: true
  path: inputs.d/*.yml

```

Any suggestion

---

<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: [July 15, 2022, 4:51am UTC](https://discuss.elastic.co/t/how-to-fix-host-issue-in-filebeat-7-17-4-without-drop-fields/306890/5 "2022-07-15T04:51:57Z")

</div>

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