# \_grokparsefailure in Logstash

**URL:** <https://discuss.elastic.co/t/grokparsefailure-in-logstash/169436>\
**Category:** Logstash\
**Created:** [February 21, 2019, 2:40pm UTC](https://discuss.elastic.co/t/grokparsefailure-in-logstash/169436 "2019-02-21T14:40:34Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Astarandel](https://avatars.discourse-cdn.com/v4/letter/a/4da419/32.png) [@Astarandel](https://discuss.elastic.co/u/Astarandel)\
**Post date:** [February 21, 2019, 2:40pm UTC](https://discuss.elastic.co/t/grokparsefailure-in-logstash/169436/1 "2019-02-21T14:40:34Z")

</div>

Greetings everyone,

I m pretty new to the whole ELK stack, please excuse me if this seems as a noob question.

I am trying to match the following log message:

`frost: (Total of 4 licenses issued; Total of 0 licenses in use)`

Using the following grok pattern:

> %{WORD:program\_name}: (Total of %{BASE10NUM:licenses\_total:int} licenses issued; Total of %{BASE10NUM:licenses\_in\_use:int} licenses in use)

I've tested the pattern with 3 different debuggers and according to them it should be fine. Unfortunately I get `_grokparsefailure`

Could you please help?

best,

Lyubo

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [February 21, 2019, 2:47pm UTC](https://discuss.elastic.co/t/grokparsefailure-in-logstash/169436/2 "2019-02-21T14:47:14Z")

</div>

Parentheses have meaning in regular expression (they define capture groups) so you need to escape them.

```
"%{WORD:program_name}: \(Total of %{BASE10NUM:licenses_total:int} licenses issued; Total of %{BASE10NUM:licenses_in_use:int} licenses in use\)"
```

---

<div class="post-metadata">

**Author:** ![Astarandel](https://avatars.discourse-cdn.com/v4/letter/a/4da419/32.png) [@Astarandel](https://discuss.elastic.co/u/Astarandel)\
**Post date:** [February 22, 2019, 8:11am UTC](https://discuss.elastic.co/t/grokparsefailure-in-logstash/169436/3 "2019-02-22T08:11:48Z")

</div>

Hello Badger...they are escaped..for some reason when I pasted the line it was not posted correctly but the line is:

`"%{WORD:program_name}: \(Total of %{BASE10NUM:licenses_total:int} licenses issued; Total of %{BASE10NUM:licenses_in_use:int} licenses in use\)"`

Sorry about the confusion 🙂

---

<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:** [March 22, 2019, 8:11am UTC](https://discuss.elastic.co/t/grokparsefailure-in-logstash/169436/4 "2019-03-22T08:11:49Z")

</div>

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