Splunk Search

Splunk Transaction command for events multiple time/day

sarwshai
Communicator

I am using this query "index=oswin* source="WinEventLog:System" (EventCode=6005 OR EventCode=1074 OR EventCode=6006) | table _time dvc EventCode | transaction dvc"
6005=evealt textnt service start
6006=event service stop
1074=server reboot

If event id 6006 at time x occurs and before and after 5 minutes of x if 6005 or 1074 occur then i dont need the output, for this i used transaction to count the duration between the 3 eventcodes and getting the output, however when in a day 2 or more reboots are done than duration i get is large as it calculates difference of between the two reboots of the same dvc.
I need separate grouping of the two reboots done.

Sample ouput attached

0 Karma

richgalloway
SplunkTrust
SplunkTrust

Try experimenting with the maxpause option of transaction. It will create separate transactions if the gap between events is large enough.

---
If this reply helps you, Karma would be appreciated.
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 ...