Getting Data In

I need a help in props.conf and transforms.conf

graju89
Path Finder

Hi,

I am new to splunk. Need some help in log filtering. I have below example log:
p 12 02:04:55 xxx,[DEFAULT_LOG] 2019-09-12 02:04:52,066 xxxxxxxxxxxxx
Sep 12 02:04:55 xxx,[AUDIT_LOG] 2019-09-12 02:04:51,309 xxxxxxxxx
Sep 12 02:04:55 xxx,[DEFAULT_LOG] 2019-09-12 02:04:51,904 xxxxxxx
p 12 02:04:55 xxx,[AUTH_LOG] 2019-09-12 02:04:52,066 xxxxxxxxxxx

I need to get only AUDIT_LOG and AUTH_LOG entry. How to write props and transforms confic file for this.

Thanks

0 Karma
1 Solution

FrankVl
Ultra Champion

Have a look at this page in docs: https://docs.splunk.com/Documentation/Splunk/latest/Forwarding/Routeandfilterdatad#Filter_event_data...

For your case, that would look something like this:

props.conf:

[yoursourcetypehere]
TRANSFORMS-set= my-setnull,my-setparsing

transforms.conf:

[my-setnull]
REGEX = .
DEST_KEY = queue
FORMAT = nullQueue

[my-setparsing]
REGEX = \[AUDIT_LOG\]|\[AUTH_LOG\]
DEST_KEY = queue
FORMAT = indexQueue

View solution in original post

0 Karma

FrankVl
Ultra Champion

Have a look at this page in docs: https://docs.splunk.com/Documentation/Splunk/latest/Forwarding/Routeandfilterdatad#Filter_event_data...

For your case, that would look something like this:

props.conf:

[yoursourcetypehere]
TRANSFORMS-set= my-setnull,my-setparsing

transforms.conf:

[my-setnull]
REGEX = .
DEST_KEY = queue
FORMAT = nullQueue

[my-setparsing]
REGEX = \[AUDIT_LOG\]|\[AUTH_LOG\]
DEST_KEY = queue
FORMAT = indexQueue
0 Karma

graju89
Path Finder

Hi FrankVI,

It worked thanks.

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 ...