# Logstash 8.6 add a field "log.file.path"

**URL:** <https://discuss.elastic.co/t/logstash-8-6-add-a-field-log-file-path/341597>\
**Category:** Logstash\
**Created:** [August 24, 2023, 5:28pm UTC](https://discuss.elastic.co/t/logstash-8-6-add-a-field-log-file-path/341597 "2023-08-24T17:28:07Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![RobertC1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/robertc1/32/98051_2.png) [@RobertC1](https://discuss.elastic.co/u/RobertC1)\
**Post date:** [August 24, 2023, 5:28pm UTC](https://discuss.elastic.co/t/logstash-8-6-add-a-field-log-file-path/341597/1 "2023-08-24T17:28:07Z")

</div>

Hi there  
I use .conf file to ingest data in my index. With the version 8.6 is added the field "log.file.path."  
I tried with  
`mutate { remove_field => ["message", "@version","host","log.file.path"] }` without suceed.  
Any help to remove this field?  
Thanks in advance.

---

<div class="post-metadata">

**Author:** ![leandrojmp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leandrojmp/32/107231_2.png) [@leandrojmp](https://discuss.elastic.co/u/leandrojmp)\
**Post date:** [August 24, 2023, 5:31pm UTC](https://discuss.elastic.co/t/logstash-8-6-add-a-field-log-file-path/341597/2 "2023-08-24T17:31:14Z")

</div>

Nested fields in Logstash are referenced using square brackets.

Replace `log.file.path` with `[log][file][path]` and it should work.

---

<div class="post-metadata">

**Author:** ![RobertC1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/robertc1/32/98051_2.png) [@RobertC1](https://discuss.elastic.co/u/RobertC1)\
**Post date:** [August 24, 2023, 6:58pm UTC](https://discuss.elastic.co/t/logstash-8-6-add-a-field-log-file-path/341597/3 "2023-08-24T18:58:40Z")

</div>

> [@leandrojmp](#):
>
> `[log][file][path]`

Thanks @leandrojmp . You are "awsom"

---

<div class="post-metadata">

**Author:** ![Rios](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rios/32/95745_2.png) [@Rios](https://discuss.elastic.co/u/Rios)\
**Post date:** [August 25, 2023, 3:33am UTC](https://discuss.elastic.co/t/logstash-8-6-add-a-field-log-file-path/341597/4 "2023-08-25T03:33:38Z")

</div>

Just to add, you can also remove a root of nested field - "log", that will remove all nested fields.

---

<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:** [September 22, 2023, 3:34am UTC](https://discuss.elastic.co/t/logstash-8-6-add-a-field-log-file-path/341597/5 "2023-09-22T03:34:24Z")

</div>

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