Splunk Search

Reporting on multiple transactions

bruceat
New Member

Hi all,

I want to track the duration of individual steps of a larger transaction. For example, I have :

2014-02-05 20:01:25 lcid=12345 Starting transaction 
2014-02-05 20:01:31 lcid=12345 Starting step A
2014-02-05 20:01:38 lcid=12345 Finished step A
2014-02-05 20:01:40 lcid=12345 Something else
2014-02-05 20:01:41 lcid=12345 Starting step B
2014-02-05 20:01:48 lcid=12345 Finished step B
2014-02-05 20:01:51 lcid=12345 Starting step C
2014-02-05 20:01:51 lcid=67890 Something else again
2014-02-05 20:01:58 lcid=12345 Finished step C
2014-02-05 20:02:00 lcid=12345 Finished transaction 

What I would like to do is to extract "step A", "step B" and "step C" durations individually.

I can do this for a single step easily enough with:
transaction lcid startswith="Starting step A" endswith="Finished step A"

Is there a way to get the duration for each of the three steps?

Thanks

Tags (1)
0 Karma

somesoni2
Revered Legend

Try this.

..your main search..| rex "lcid=[\d]*\s(?<status>[^ ]*)\s(step |trans)(?<actor>[^ ]*)" | eval actor=if(actor="action","Main",actor) | transaction actor startswith="Starting" endswith="Finished"
0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to May Tech Talks, Office Hours, and Webinars!

Take a look below to explore our upcoming Community Office Hours, Tech Talks, and Webinars this month. This ...

They're back! Join the SplunkTrust and MVP at .conf24

With our highly anticipated annual conference, .conf, comes the fez-wearers you can trust! The SplunkTrust, as ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had two releases of new security content via the Enterprise ...