Getting Data In

event tagging ..Multiple format lines in same log file

desi-indian
Path Finder

Hi ,
I am trying to do a field extraction for a log ...the issue I am facing is the field lay out remains constant works fine for 90 % time but for remaining 10 % the log format changes

Example :

when I have a message line with "Authenticated" In there the user_ID is 9 th field

BUT when I have "LOGOFF" in the line the User_ID is coming in as 7 th field .

How do I define my props/transforms so I am capturing ALL User_IDs irrespective If it comes in 7 th field or 9 th field ?

Thanks for the help !

0 Karma

aalanisr26
Path Finder

if for example you have:

First Kind of event,Some More field,Authentication,7,More,More
Second Kind of event,Data,Data,Data,Data,Data,Data,LogOFF,7,More,More

if you want to get the 7

(Authentication\,\d+|LogOFF\,\d)

0 Karma

lguinn2
Legend

And a few lines from a log file, showing the alternate formats, would be helpful, too. You should anonymize any identifying data. Thanks!

0 Karma

ftk
Motivator

Can you post your current extractions from props.conf and transforms.conf?

0 Karma
Get Updates on the Splunk Community!

Routing logs with Splunk OTel Collector for Kubernetes

The Splunk Distribution of the OpenTelemetry (OTel) Collector is a product that provides a way to ingest ...

Welcome to the Splunk Community!

(view in My Videos) We're so glad you're here! The Splunk Community is place to connect, learn, give back, and ...

Tech Talk | Elevating Digital Service Excellence: The Synergy of Splunk RUM & APM

Elevating Digital Service Excellence: The Synergy of Real User Monitoring and Application Performance ...