Splunk Search

Linking outbound and inbound messages, then finding incomplete ones

wardallen
Path Finder

I am analysing a logfile where there'll be a message that describes an outbound message going to an external system, and a short period of time later, a reciprocal message from the external system - a "job done" message, containing a unique deal ID common to both.
Finding the out and in messages won't be hard.
The hard part will be writing a query that tells me about all deal IDs that have an outbound but not an inbound component. What would be the best approach to do this?

Tags (1)
0 Karma
1 Solution

kristian_kolb
Ultra Champion

I can think of at least the following (where deal_ID would be the field that contains the ... deal ID);

... | transaction deal_ID | where eventcount < 2

and slightly faster:

... | stats count by deal_ID | where count < 2

/K

View solution in original post

kristian_kolb
Ultra Champion

I can think of at least the following (where deal_ID would be the field that contains the ... deal ID);

... | transaction deal_ID | where eventcount < 2

and slightly faster:

... | stats count by deal_ID | where count < 2

/K

kristian_kolb
Ultra Champion

The first search will return the whole outbound event, and the second search will just return the deal_ID of the lonely outbound event.

/k

wardallen
Path Finder

Also, there will be other pairs starting/finishing at the same time. Processing is not linear.

0 Karma
Get Updates on the Splunk Community!

Threat Hunting Unlocked: How to Uplevel Your Threat Hunting With the PEAK Framework ...

WATCH NOWAs AI starts tackling low level alerts, it's more critical than ever to uplevel your threat hunting ...

Splunk APM: New Product Features + Community Office Hours Recap!

Howdy Splunk Community! Over the past few months, we’ve had a lot going on in the world of Splunk Application ...

Index This | Forward, I’m heavy; backward, I’m not. What am I?

April 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...