Getting Data In

How to split single line event into multiple events based on pattern?

flucman
Explorer

Is it possible to split a single line event into multiple based on a pattern? Ex. I have:

SNMPv2-SMI::enterprises."4551.5.1.1.1.1.4.8.4.1.6.1.1" = "4.168961" SNMPv2-SMI::enterprises."4551.5.1.1.1.1.4.8.4.1.9.1.1" = "1"

on one line and want to split it into two SNMP events. I have been testing with LINE_BREAKER and BREAK_ONLY_BEFORE in props.conf but not having any luck. Have tried the below (one at a time):

BREAK_ONLY_BEFORE = SNMPv2

LINE_BREAKER = ([\r\n]+)|SNMPv2

Thanks!

0 Karma

chanfoli
Builder

Something along the lines of this will cause it the see the string as your line breaker and appears to break the events up, with the side effect of disposing of the line breaker text:

LINE_BREAKER=(SNMPv2-SMI)
NO_BINARY_CHECK=1
SHOULD_LINEMERGE=false

Get Updates on the Splunk Community!

AppDynamics Summer Webinars

This summer, our mighty AppDynamics team is cooking up some delicious content on YouTube Live to satiate your ...

SOCin’ it to you at Splunk University

Splunk University is expanding its instructor-led learning portfolio with dedicated Security tracks at .conf25 ...

Credit Card Data Protection & PCI Compliance with Splunk Edge Processor

Organizations handling credit card transactions know that PCI DSS compliance is both critical and complex. The ...