# Need help for the correct multline pattern

**URL:** <https://discuss.elastic.co/t/need-help-for-the-correct-multline-pattern/127246>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [April 9, 2018, 5:54am UTC](https://discuss.elastic.co/t/need-help-for-the-correct-multline-pattern/127246 "2018-04-09T05:54:44Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Vipra3003](https://avatars.discourse-cdn.com/v4/letter/v/a183cd/32.png) [@Vipra3003](https://discuss.elastic.co/u/Vipra3003)\
**Post date:** [April 9, 2018, 5:54am UTC](https://discuss.elastic.co/t/need-help-for-the-correct-multline-pattern/127246/1 "2018-04-09T05:54:44Z")

</div>

Hi  
I have to write multiline pattern in the filebeat.yml for the below logs for a tomcat server  
Please suggest what would be the correct pattern

2018-02-24 09:11:25,757 localhost-startStop-2 INFO [c.a.jira.startup.DefaultJiraLauncher] Stopping launchers  
2018-02-24 09:11:25,761 localhost-startStop-2 ERROR [o.a.c.c.C.[Catalina].[localhost].[/]] Exception sending context destroyed event to listener instance of class com.atlassian.jira.startup.LauncherContextListener  
java.lang.NullPointerException  
at com.atlassian.jira.startup.ClusteringLauncher.stop(ClusteringLauncher.java:31)  
at com.atlassian.jira.startup.DefaultJiraLauncher.stop(DefaultJiraLauncher.java:166)  
at com.atlassian.jira.startup.LauncherContextListener.contextDestroyed(LauncherContextListener.java:127)  
at org.apache.catalina.core.StandardContext.listenerStop(StandardContext.java:4751)  
at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5352)  
... 3 filtered  
at java.util.concurrent.FutureTask.run(FutureTask.java:266)  
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)  
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)  
at java.lang.Thread.run(Thread.java:745)  
24-Feb-2018 09:11:25.804 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-8080"]  
24-Feb-2018 09:11:25.805 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-8080"]  
24-Feb-2018 10:31:31.600 WARNING [main] org.apache.tomcat.util.digester.SetPropertiesRule.begin [SetPropertiesRule]{Server/Service/Engine/Valve} Setting property 'resolveHosts' to 'false' did not find a matching property.

Regards  
Vipra Bhatia

---

<div class="post-metadata">

**Author:** ![kvch](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kvch/32/72058_2.png) [@kvch](https://discuss.elastic.co/u/kvch)\
**Post date:** [April 9, 2018, 9:37am UTC](https://discuss.elastic.co/t/need-help-for-the-correct-multline-pattern/127246/2 "2018-04-09T09:37:12Z")

</div>

Please format your logs using `</>`, so a correct pattern can be worked out.

With this unformatted log I assume it's possible to match for timestamps. But without the formatted logs I am not sure it works, so please test it.

```auto
multiline.pattern: '^[0-9]{4}-[0-9]{2}-[0-9]{2}'
multiline.negate: true
multiline.match: after

```

You can find more examples here: [https://www.elastic.co/guide/en/beats/filebeat/6.2/\_examples\_of\_multiline\_configuration.html](https://www.elastic.co/guide/en/beats/filebeat/6.2/_examples_of_multiline_configuration.html)

---

<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:** [May 7, 2018, 9:37am UTC](https://discuss.elastic.co/t/need-help-for-the-correct-multline-pattern/127246/3 "2018-05-07T09:37:24Z")

</div>

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