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 Splunk Community Dashboard Challenge!

Welcome to Splunk Community Dashboard Challenge! This is your chance to showcase your skills in creating ...

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer Certification at ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...