# How to write grok filter

**URL:** <https://discuss.elastic.co/t/how-to-write-grok-filter/92213>\
**Category:** Logstash\
**Created:** [July 7, 2017, 6:19am UTC](https://discuss.elastic.co/t/how-to-write-grok-filter/92213 "2017-07-07T06:19:12Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![rp311286](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rp311286/32/19619_2.png) [@rp311286](https://discuss.elastic.co/u/rp311286)\
**Post date:** [July 7, 2017, 6:19am UTC](https://discuss.elastic.co/t/how-to-write-grok-filter/92213/1 "2017-07-07T06:19:12Z")

</div>

here is my log file format

---Exception occure at 31-03-2017 11:19:25-------  
Error line no:233 ErrorMessage: DllNotFoundException ExceptionType: System.DllNotFoundException ControllerName: SocialmediaCountController ActionName: GetDownload url: [http://193.168.1.79/xyz/api/1/emailCampaignReportDownLoad/100000Mails/1187](http://193.168.1.79/xyz/api/1/emailCampaignReportDownLoad/100000Mails/1187) InnerException:  
-------_End_----------  
---Exception occure at 31-03-2017 11:35:53-------  
Error line no:233 ErrorMessage: DllNotFoundException ExceptionType: System.DllNotFoundException ControllerName: Yavun.Controllers.ECampaign.SocialmediaCountController ActionName: GetReport url: [http://193.168.1.79/yavun/api/1336/emailCampaignReport/811?email=abc@gmail.com](http://193.168.1.79/yavun/api/1336/emailCampaignReport/811?email=abc@gmail.com) InnerException: null  
-------_End_----------

and so on  
what will be the filter expression?

grok {  
match =\> ?  
}

---

<div class="post-metadata">

**Author:** ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)\
**Post date:** [July 7, 2017, 9:35am UTC](https://discuss.elastic.co/t/how-to-write-grok-filter/92213/2 "2017-07-07T09:35:48Z")

</div>

Have you tried using the grok constructor web site to build your expression?

---

<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 4, 2017, 9:35am UTC](https://discuss.elastic.co/t/how-to-write-grok-filter/92213/3 "2017-08-04T09:35:48Z")

</div>

Closed on August 4, 2017, 9:35am UTC

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