# Grok pattern need

**URL:** <https://discuss.elastic.co/t/grok-pattern-need/173024>\
**Category:** Logstash\
**Created:** [March 19, 2019, 4:58pm UTC](https://discuss.elastic.co/t/grok-pattern-need/173024 "2019-03-19T16:58:31Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![nagr](https://avatars.discourse-cdn.com/v4/letter/n/aeb1de/32.png) [@nagr](https://discuss.elastic.co/u/nagr)\
**Post date:** [March 19, 2019, 4:58pm UTC](https://discuss.elastic.co/t/grok-pattern-need/173024/1 "2019-03-19T16:58:31Z")

</div>

Hi All,

Could you share your thought to get the exact grok pattern for the below content,

log file --\> "ServerManager~31bf3856ad364e35~amd64~~6.3.9600.16384, Remote Parent: IIS-HttpErrors, Intended State: Staged"

so the grok pattern how will write,

I want message =\> "IIS-httpErrors" feet in to elasticsearch

Thanks,  
Nagaraj,

---

<div class="post-metadata">

**Author:** ![pup\_seba](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/pup_seba/32/42988_2.png) [@pup\_seba](https://discuss.elastic.co/u/pup_seba)\
**Post date:** [March 19, 2019, 7:33pm UTC](https://discuss.elastic.co/t/grok-pattern-need/173024/2 "2019-03-19T19:33:18Z")

</div>

Hi,

There are infinite ways of filtering this log...most likely mine is not the better one, but I hope it helps you anyways.

`^ServerManager~[^:]+:\s(?<yourlabelhere>[\w-]+)[^:]+:\sStaged$`

Regards!

---

<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:** [April 16, 2019, 7:33pm UTC](https://discuss.elastic.co/t/grok-pattern-need/173024/3 "2019-04-16T19:33:19Z")

</div>

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