# Multiline match wrong

**URL:** <https://discuss.elastic.co/t/multiline-match-wrong/195292>\
**Category:** Logstash\
**Created:** [August 15, 2019, 3:45am UTC](https://discuss.elastic.co/t/multiline-match-wrong/195292 "2019-08-15T03:45:08Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![cevin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cevin/32/52342_2.png) [@cevin](https://discuss.elastic.co/u/cevin)\
**Post date:** [August 15, 2019, 3:45am UTC](https://discuss.elastic.co/t/multiline-match-wrong/195292/1 "2019-08-15T03:45:09Z")

</div>

log file

```auto
---------------------------------------------------------------
[2019-08-14T09:16:11+08:00] 127.0.0.1 GET localhost:8000/
[error] xxx
[error] xxxxx
[error] xxxxx

---------------------------------------------------------------
[2019-08-14T09:16:11+08:00] 127.0.0.1 GET localhost:8000/
[error] xxx
[error] xxxxx
[error] xxxxx

---------------------------------------------------------------
[2019-08-14T09:16:11+08:00] 127.0.0.1 GET localhost:8000/
[error] xxx
[error] xxxxx
[error] xxxxx

---------------------------------------------------------------
[2019-08-14T09:16:11+08:00] 127.0.0.1 GET localhost:8000/
[error] xxx
[error] xxxxx
[error] xxxxx

```

```auto
filter {
    multiline {
        what => previous
        negate => true
        pattern => "/^---------------------------------------------------------------\r\n$/g"
    }
}

```

got:

```auto
![](https://cdck-file-uploads-us1.s3.dualstack.us-west-2.amazonaws.com/elastic/original/3X/c/c/ccace88e25967944c19b1291059705e44535fac3.png)

```

just only one message :(..

---

<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 12, 2019, 3:55am UTC](https://discuss.elastic.co/t/multiline-match-wrong/195292/2 "2019-09-12T03:55:24Z")

</div>

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