# How to filter specific fields of nginx logs in filebeat before importing in elastic?

**URL:** <https://discuss.elastic.co/t/how-to-filter-specific-fields-of-nginx-logs-in-filebeat-before-importing-in-elastic/351475>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [January 20, 2024, 12:54pm UTC](https://discuss.elastic.co/t/how-to-filter-specific-fields-of-nginx-logs-in-filebeat-before-importing-in-elastic/351475 "2024-01-20T12:54:37Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![stephenb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephenb/32/40856_2.png) [@stephenb](https://discuss.elastic.co/u/stephenb)\
**Post date:** [January 21, 2024, 4:18pm UTC](https://discuss.elastic.co/t/how-to-filter-specific-fields-of-nginx-logs-in-filebeat-before-importing-in-elastic/351475/4 "2024-01-21T16:18:24Z")

</div>

Hi @Siavash_Fazli

So there are 2 ways to do this

1. Easiest but perhaps not best long term : Add a `remove` processor to the end of the existing pipeline

2. Clone the pipeline and then add the `remove` processor to your customer pipeline and use that pipeline in the module [Here](https://discuss.elastic.co/t/help-parsing-custom-nginx-logs-using-filebeat-and-ingest-pipelines/349974/6) are detailed instructions for that ... but for you instead of all the `grok` stuff you would just add the `remove` processor as the last processor..

So for Number 1)

Go to Kibana - Stack Management - Ingest Pipeline

Find the nginx access pipeline - 1st Clone it for a backup, then Edit the original pipeline

 ![Screenshot 2024-01-21 at 8.11.51 AM](https://us1.discourse-cdn.com/elastic/original/3X/b/e/becfdd2cdac90b5d6150a529827470b1d97167a8.png)

at the bottom of the normal processors add a `remove` processor and list the fields you want to remove... IMPORTANT don't forget to save the processor and pipeline

 ![Screenshot 2024-01-21 at 8.16.58 AM](https://us1.discourse-cdn.com/elastic/original/3X/a/6/a68f50f0d94a0c054da759141a0ba649ee2c7b30.jpeg)

Let us know how it works...

---

_[View the full topic](https://discuss.elastic.co/t/how-to-filter-specific-fields-of-nginx-logs-in-filebeat-before-importing-in-elastic/351475)._
