Getting Data In

keep some events and discard the rest

trkalva
Engager

i have a huge log file with events, i need to keep around 20-30 events and discard the rest. I have used a stanza in transforms.conf with a REGEX=(MATCH-1 | MATCH-2 | MATCH-3 |..|..|... MATCH-N), such that the events which match with REGEX are in and the rest are sent to nullQueue.

Is there a better way to write instead of writing (MATCH-1 | MATCH-2 | MATCH-3 |..|..|... MATCH-N) in the REGEX?

Please guide..

Tags (1)
0 Karma
1 Solution

carmackd
Communicator

I'm sure you can optimize your regex to match multiple criteria. Can you provide examples of the events you're trying to filter?

View solution in original post

0 Karma

carmackd
Communicator

I'm sure you can optimize your regex to match multiple criteria. Can you provide examples of the events you're trying to filter?

0 Karma
Get Updates on the Splunk Community!

More Ways To Control Your Costs With Archived Metrics | Register for Tech Talk

Tuesday, May 14, 2024  |  11AM PT / 2PM ET Register to Attend Join us for this Tech Talk and learn how to ...

.conf24 | Personalize your .conf experience with Learning Paths!

Personalize your .conf24 Experience Learning paths allow you to level up your skill sets and dive deeper ...

Threat Hunting Unlocked: How to Uplevel Your Threat Hunting With the PEAK Framework ...

WATCH NOWAs AI starts tackling low level alerts, it's more critical than ever to uplevel your threat hunting ...