Splunk Search

Key Value pair extraction with unique value

mayank141
New Member

Hi,

I need to extract unique values as per below sample data

Its has unique format like [ parameter : mailboxName | value : mail\tdev2.nsf], how to extract the data with parameter name and its value?

[2017-11-06]T[16:33:21.122]Z 31 WebContainer : 4 WARNING [ parameter : mailboxName | value : mail\xdevx.xxx];[ parameter : userID | value : CN=Test Dev2/OU=US/O=xxxDEV];[ parameter : OPERATION | value : SEARCH ];[ parameter : session | value : eSbBsoxxxxxx_O9AIxxxxxx ] [com.xxx.xxx.actions.MainAction: execute]

Please advise.

Thanks
Mayank

0 Karma

MuS
Legend

Hi mayank141,

you can use the search time reporting transforms in props.conf and transforms.conf to get this captured:
props.conf

[mySourceType]
REPORT-myUniqueClassName = myTransform

transforms.conf

[myTransform]
REGEX = \[\s\w+\s:\s(\w+)\s\|\s\w+\s:\s([^\]]+)
FORMAT = $1::$2

This will capture the value after parameter : as field name and the value after value : as value of the field.

Hope this helps ...

cheers, MuS

0 Karma

cpetterborg
SplunkTrust
SplunkTrust

Search time or index time field extraction?

0 Karma
Get Updates on the Splunk Community!

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics GA in US-AWS!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...