Splunk Search

Having trouble extracting these feilds...

richnavis
Contributor

Can't seem to make this work.. using a " " delimter in my transforms didn't do the trick..

www-ber 10/18/2013-02:59 85 up OK

www-pcr 10/18/2013-01:44 64 down HTTP Error 503

Any suggestions?

Tags (2)
0 Karma
1 Solution

kristian_kolb
Ultra Champion

Did you use DELIMS=" "? And it didn't work because you have some strings with spaces that you wanted to extract as one field? Then perhaps you should try a different approach;

props.conf

[your sourcetype]
EXTRACT-blah = ^(?<field1>\S+)\s+(?<field2>\S+)\s+(?<field3>\d+\s\w+)\s(?<field4>.*)

/K

View solution in original post

kristian_kolb
Ultra Champion

Did you use DELIMS=" "? And it didn't work because you have some strings with spaces that you wanted to extract as one field? Then perhaps you should try a different approach;

props.conf

[your sourcetype]
EXTRACT-blah = ^(?<field1>\S+)\s+(?<field2>\S+)\s+(?<field3>\d+\s\w+)\s(?<field4>.*)

/K

richnavis
Contributor

Thanks.. This worked!

0 Karma

jtrucks
Splunk Employee
Splunk Employee

what have you tried so far, and do you want the date/time to be a single field or broken up?

--
Jesse Trucks
Minister of Magic
0 Karma
Get Updates on the Splunk Community!

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...

Splunk Custom Visualizations App End of Life

The Splunk Custom Visualizations apps End of Life for SimpleXML will reach end of support on Dec 21, 2024, ...