Getting Data In

match multi-line event

bob87
Explorer

I am indexing multi-line events and would like to exclude events like the following:

2012-12-04 16:29:22.402 Some text failed:
From: ExecuteViewBasedLookupCC::Execute
Type: LogicError
Severity: Critical
Text: (vector (Null-null) 3.60206e+11 )

The rule for excluding events is the text ExecuteViewBasedLookupCC followed by (Null-null). I am using the following regular expression to match this event and redirect it to nullQueue:

REGEX=(?m)^.*ExecuteViewBasedLookupCC(?=.*(Null-null))

However it is not working. Any ideas please?

Tags (2)
0 Karma
1 Solution

Ayn
Legend

You need to use the s modifier as well in order to have the dot match newlines. So (?ms)

http://www.regular-expressions.info/modifiers.html

View solution in original post

Ayn
Legend

You need to use the s modifier as well in order to have the dot match newlines. So (?ms)

http://www.regular-expressions.info/modifiers.html

bob87
Explorer

thanks, that worked!

0 Karma
Get Updates on the Splunk Community!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...